Greetings again!
Our application, written in MS Visual C++ 6, allows a user to display Crystal Reports reports. Our application creates a window to hold the report display, then tells the viewer control to use the client area of the new window, and then calls the CR viewer control's ViewReport() method. At that point, the viewer control and our main application run separately. If the report requires the user to select parameters, the viewer displays a dialog box for them. If the user clicks Cancel on that box, a little message box appears saying "User cancelled", and the viewer control doesn't do anything more. However, the original window still exists. The user would like that window to go away automatically.
I see that a report object can raise four different events, including a NoData event. Does that event get raised when the Cancel button is clicked?
I also see that the Crystal Reports object model includes a class named IReportEvent, and there are methods in that class related to the events a report object can raise. However, to use that class, one must know how to implement a COM event sink. I do not know how to do that. Can anyone show me an example of how to implement an event handler for the NoData event in MS Visual C++ 6?
Thank you very much.
RobR
Edited by RobR - 02 Jun 2009 at 5:54am