?
Solved

previewing report using RDC  in crystal reports  9

Posted on 2003-02-20
4
Medium Priority
?
1,635 Views
Last Modified: 2007-12-19
Hello,
Al trying to automate crystal reports using Microsoft vc++.My application works perfect with old versions of crystal report.But With the version 9 i have a problem in previewing the report.
I studied that the  crystal report version 9 comes with a new automation server Craxdrt9.dll instead of CPEAUT32.dll.
Inorder to upgrade my application i had to find out the new dispatch IDS of the “CrystalRuntime.Application” automation server.
I got the  Dispatch Ids of all the methods by opening the CRAXDRT.TLB file in OLE/COM object viewer.

But i am unable to get the dispath ID of the preview function which was working perfectly with the old automation server.Can anybody give an expert advice on this.AM STUCK:(
Thanks in advance
0
Comment
Question by:kaljess
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 101

Expert Comment

by:mlmcc
ID: 7991351
Did you try using the old method with CR9?  I was under the impression that the automation engine was still there.

What code are you using?

Take a look at

http://support.crystaldecisions.com/communityCS/FilesAndUpdates/rdccpp85.exe.asp

mlmcc
0
 

Author Comment

by:kaljess
ID: 8150031
I did some Research on it and found
The crystal report version 9 does not have a Report Engine Automation Server component unlike its previous versions. It has Report Development Component and Crystal Reports Viewers for the same purpose.
The only way to upgrade crystal reports to version 9.0 is to migrate from Report Engine Automation Server component suite to those of the Crystal RDC (Report Development Component).

For reference see
http://support.crystaldecisions.com/library/kbase/articles/c2003667.asp
http://www.hammerapps.com/techtips/techtipsasp/techtipsdynamic.asp?TTID=77



Changes to be made to migrate to crsytal report 9.0(vc++ environment)


The new Crystal reports Report Development Component“CrystalRuntime.Application” (Craxdrt9.dll) has to be used instead of  “Crystal.CRPE.Application”
(CPEAUT32.dll) for automating crystal reports from CIS

To accomplish this Modify Initialize () function in Qcrystal.rpt

BSTR b = T2BSTR ("Crystal.CRPE.Application");

to

BSTR b = T2BSTR ("CrystalRuntime.Application");



Get exact Dispatch ID’s of  Report Development Component
“CrystalRuntime.Application”

Dispatch ID’s are used to access exposed automation server’s objects and also to invoke their methods.

An analysis revealed that the Dispatch ID’s of Craxdrt9.dll (version 9) and CPEAUT32.DLL (old version) differs making the automation process for crystal reports version 9.0 fail in CIS.

Dispatch Ids can be obtained by opening the CRAXDRT.TLB file in OLE/COM object viewer.

Also to retrieve the descriptions of objects, collections, methods, and properties of Report design automation object download
http://support.crystaldecisions.com/communityCS/TechnicalPapers/rdc8_browser.exe.asp

The Dispatch Ids can also be retrieved using the GetIDsOfNames () function.

EG.

InvokeHelper (0x5, DISPATCH_METHOD, VT_DISPATCH, (void*)&result, parms, ReportFileName);

to

InvokeHelper (0x120, DISPATCH_METHOD, VT_DISPATCH, (void*)&result, parms, ReportFileName);

Replace all the old dispatch IDs with new dispatch IDs

Thanks
jess
0
 

Accepted Solution

by:
modulo earned 0 total points
ID: 11815089
PAQed, with points refunded (20)

modulo
Community Support Moderator
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

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

I hate sub reports and always consider them the last resort in any reporting solution.  The negative effect on performance and maintainability is just not worth the easy ride they give the report writer.  Nine times out of ten reporting requirements…
There have always been a lot of questions related to when Crystal Reports evaluates report components (such as formulas, summaries, cross-tabs, charts, to name a few examples). Crystal Reports uses a two-pass reporting process to provide greater …
Sometimes it takes a new vantage point, apart from our everyday security practices, to truly see our Active Directory (AD) vulnerabilities. We get used to implementing the same techniques and checking the same areas for a breach. This pattern can re…
Have you created a query with information for a calendar? ... and then, abra-cadabra, the calendar is done?! I am going to show you how to make that happen. Visualize your data!  ... really see it To use the code to create a calendar from a q…
Suggested Courses

770 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