I believe that one must first preview a worksheet before one can return the
print page count. It may be possible to get the count to work by changing
to page break preview first. Try the sample codes immediately after opening
Excel and before printing or do a preview to see if they work.
Robert Flanagan
http://www.add-ins.com
Productivity add-ins and downloadable books on
VB macros for Excel
"Charlotte E" <@ wrote in message
...
Hello,
When I press 'Preview Print' it says, at the buttom, how many pages the
spreadsheet will use upon being printed, i.e.: "Page 1 of 4".
Is it possible to optain this number (4) in VBA and assign it to a
variable?
TIA,