Solved

Get Crystal Report Recordcount Using VB6

Posted on 2002-03-05
1
511 Views
Last Modified: 2007-12-19
Hello All,

I'm using Crystal Reports 8.5 and VB6. What I have is an automated process that runs several reports. I would like to load the report recordcount into a variable to be used in my VB code. How do I pull that info. I'm using the following connection string into my Oracle DB. I've also included my print code. Please include an example. I'll give this one high points because it will help me out big time. Thanks in advance for any help you can give me.

Thanks

' Logs onto server in Crystal Reports
  crApplication.LogOnServer "p2sodbc.dll", "O8IPROD", O8IPROD, "username", "password"
 
  ' Prints the Customer Copy Invoices
  Set crReport1 = crApplication.OpenReport("c:\test_invoice_GSCopy.rpt")

crReport1.DiscardSavedData

crReport1.PrintOut False

0
Comment
Question by:mts9
1 Comment
 
LVL 4

Accepted Solution

by:
P1 earned 300 total points
ID: 6841961
Well there's:

Read% = CrystalReport1.RecordsRead
Printed& = CrystalReport1.RecordsPrinted
Selected& = CrystalReport1.RecordsSelected

These work with top level report, if the report itself has sub-reports, total records involved may not be available.

See Developer's Help file for more details.

Enjoy your work,  P1
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Have you ever wanted to restrict the users input in a textbox to numbers, and while doing that make sure that they can't 'cheat' by pasting in non-numeric text? Of course you can do that with code you write yourself but it's tedious and error-prone …
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

829 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question