Macro-Calc-Count Printing Pages of a sheet

I need a macro that shows (in a Long or Integer variable) the amount of pages on spreadsheet to be printed

.getRendererCount()?

1 Like

Sorry. I saw the solution in a forum (It´s a simple three line code), but I missed it.
I use Basic. (ThisComponent.CurrentController.ActiveSheet for example)

Unbelievable…I found the solution. I found it, but I can´t find it again…The solution is lost in some dark deep place on internet.

It is like the “executeexcel4macro( get.document(50) )” macro command on Excel

The solution is above (from @JohnSUN ). :slightly_smiling_face:
Try (for first sheet):

i=ThisComponent.getRendererCount(ThisComponent.Sheets(0), Array())

It´s worked…You´re GREAT. Thanks, thanks, thanks. I don´t know you, but I loved you…Thank you SOOOOO MUCH.