
Tips.Net > WordTips Home > Macros > WordBasic Examples > Determining the Number of Pages in Your Document with WordBasic
Summary: How to determine the number of document pages within a WordBasic macro. (This tip works with Microsoft Word 6, and Word 95.)
There may be times in your WordBasic macros when you need to determine the number of pages in a document. The following code will tell you the number of pages in a document:
TtlPgs = SelInfo(4)
The number returned represents the total physical pages in your document.
Tip #725 applies to Microsoft Word versions: 6 95
Find and Replace Almost Anything! An invaluable resource for learning how to harness the full power of Word's search and replace capabilities. You'll discover everything you need in order to master all the intricacies of finding and replacing elements of your document, including the super-powerful "wildcard searches" available in Word.
Check out WordTips: Find and Replace today!
The real power behind Word's best documents lies in understanding styles and templates. Learn the key to more powerful document creation. (more information...)
Ask a Word Question
Make a Comment
Beauty Tips
Bugs and Pests Tips
Car Tips
Cleaning Tips
College Tips
Cooking Tips
Excel2007 Tips
ExcelTips
Family Tips
Gardening Tips
Health Tips
Home Tips
Money Tips
Organizing Tips
Pet Tips
Word2007 Tips
WordTips