We used Microsoft Dynamic Navision 5, Microsoft SQL Server 2005 and Crystal Report, We try to call Crsytal Report from Microsoft Dynamic Navision 5 but we are failed.
I don’t need to use the function “Hyperlink” to call the report because later i want to send paramter to the report.
I tried the following:
//------ We use this 3 variables:
CRApp1: Automation Subtype: ‘Crystal Reports ActiveX Designer Design and Runtime Library 10.5’.Application
CRReport1:Automation Subtype: ‘Crystal Reports ActiveX Designer Design and Runtime Library 10.5’.Report
CrViewer1:Automation Subtype:‘Crystal ActiveX Report Viewer Library 10.5’.CrystalActiveXReportViewer
//---- end of We use this variables
//------ CrystalReport1.rpt is a very simple report.It is involved just one label but I don’t want to use the function “Hyperlink” to call the report because later i want to complicate this report.
CREATE(CRApp1);
CREATE(CrViewer1)
CRReport1 := CRApp1.OpenReport(‘C:\Documents and Settings\mkitani\Desktop\CrystalReport1.rpt’,0);
CrViewer1.ReportSource:=CRReport1;
CrViewer1.ViewReport();
In compilation i don’t get any error, but when i run the code i Get the error on the line
“CrViewer1.ReportSource:=CRReport1;”
and i show this message:
The data type is not supported by C/SIDE. You can access data from any of the following data types: VT_VOID, VT_I2, VT_I4, VT_R4, VT_R8, VT_CY, VT_DATE, VT_BSTR and VT_BOOL.
Please i need help to solve this problem if any body has a better idea or solution I really appreciate that.
This is My Email:Mohamadkhodoritani@yahoo.com for any example or tutorial.
Thank you for your cooperation