table printing: number of pages

Hi all,
I use PrintTable and I need to ask confirmation before printing only if
there are a lot of pages to be printed.

How can I know how many pages are going to be printed?

I have
stampa = PrintTable(self.frame)
and
stampa.GetTotalPages() returns 100, but if I look at the preview, I can
see only 4 pages...

wxPython2.4.1 on linux

Thanks
-fc

Federico Collazuol wrote:

Hi all,
I use PrintTable and I need to ask confirmation before printing only if
there are a lot of pages to be printed.

How can I know how many pages are going to be printed?

I have
stampa = PrintTable(self.frame)
and
stampa.GetTotalPages() returns 100, but if I look at the preview, I can
see only 4 pages...

Because of limitations in the printing framework in 2.4 and prior versions, the number of pages that need printed are not able to be calculated before the print is actually being done. I believe that this has been changed in 2.5 though...

ยทยทยท

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!