![]() |
|
#2
|
||||
|
||||
|
So you already have a VBA program that calculates the number of pages, and displays it using MsgBox, right? If you want your program to put that number in a cell of a worksheet, the code looks something like this:
Code:
set ows = ActiveSheet npg = (ows.HPageBreaks.Count + 1) * (ows.VPageBreaks.Count + 1) set ocs = ows.Cells ocs(1, 1).Value = npg 'row 1, col 1 |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
Number Pages - not total pages, but actual pages.
|
Kiminator321 | Word | 8 | 04-29-2020 03:07 PM |
| Count number of days | walidriachi | Word VBA | 5 | 07-23-2018 12:13 AM |
count a number of cells based on the beginning of a order number
|
Kubi | Excel | 2 | 08-06-2017 08:54 PM |
Count Number of Pages in Document with Footnotes
|
d4okeefe | Word VBA | 5 | 11-11-2013 11:02 AM |
page count increases on its own -inserts white pages
|
itsema | Word | 1 | 03-06-2013 12:48 PM |