on 05-01-2009 2:59 PM
Hi... i didn't think that the new crystal report 2008 could be so different to use from crystal 8!
I have a simple question. how cai i know the totalpagecount from vb? i need this parameter because i need to show a printdialog with "from page to page" before calling .printtoprinter method...
in vb6 with crystal 8 i just write:
Rpt.PrintingStatus.NumberOfPages
and now??????
P.S.: i can't understand why the old RDC was much more easy to use! with VB6 i can add sort field, get number of pages... etc. now i had to write a book!!!
Try this:
The following sample code demonstrates how to retrieve the number of pages from your 'ReportDocument' object. Assuming that your 'ReportDocument object' is called 'crReport', use the following VB.NET code to return the number of pages in a report:
====================
NOTE:
Logon and parameter field values must be provided prior to executing this code.
====================
Dim nPages as Integer
nPages = crReport.FormatEngine.GetLastPageNumber(New CrystalDecisions.Shared.ReportPageRequestContext)
Jason
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
It is in Note [1216240 |https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/oss_notes_boj/sdn_oss_boj_dev/sap(bD1lbiZjPTAwMQ==)/bc/bsp/spn/scn_bosap/notes.do]
You will want to search the notes database for information like this.
The formatengine is undocumented so I do not know about that, but I dont think you would use it to add a sort field at runtime.
Create a new thread asking that question and maybe someone has code already for it.
Make sure you search the forum first.
Jason
User | Count |
---|---|
90 | |
10 | |
10 | |
10 | |
7 | |
7 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.