Hi all.
I've been searching this forum for so many hours and I can't find the solution to my problem.
I have created a report using Crystal Reports 9. I have saved it as Report1.rpt in c:\
I have a button in a form and in its Push event I want to enter code that displays Report1.rpt.
I do not know what Automation objects to create and how to use them in order to define the filename of the report and display it to the user. (I do not wish to use HYPERLINK!!) I have found some sample code in this forum but no one explicitly mentions what subtype the Automation object is and what class it is.
After I get this right, the next step will be to pass variables to the saved report, in order to filter the data displayed.
Thank you in advance,
Jorgito
0
Comments
I created a report and used the table Customer as DataItem.
I created 3 variables
CRViewer Automation 'Crystal Report Viewer Control'.CRViewer
CRReport Automation 'Crystal Reports 9 ActiveX Designer Design and Runtime Library'.Report
CRApp Automation 'Crystal Reports 9 ActiveX Designer Design and Runtime Library'.Application
Then I entered the following code:
When I run it, I get the following error:
Any ideas? Should I use OCX instead of Automation objects? If yes, how?
Thanx in advance,
Jorgito
here is a link to a discussion on it
http://dynamicsuser.net/forums/thread/3561.aspx
good luck
I must have been chatty that day - but the first post says he doesn't want to use Hyperlink. It sounds he already search the forum for "Crystal" :-k
I simply don't have the time to test it right now.
http://www.BiloBeauty.com
http://www.autismspeaks.org
It seems a little strange that no one has a solution for my problem. You mean that no one has tried to open crystal reports from within navision? Everyone is either using standard navision reports or external (and complicated) mis tools?
What I want to do is create more complicated reports that standard navision reports. If someone has another solution that Crystal, please let me know...
Thanx
Jorgito
1. Make more complicated reports in Navision, and use the Navision tools, not too hard to learn.
2. Make other reports with Crystal and use Hyperlink from Navision, so user can run them without having to know anything.
3. For user that need more complicated thing, I make a Crystal report and show then how to run it on there own.
It seems you want your users to be able to run really complicated reports without having to know anything, and that is tough to do. What I have found is if your users are running really complicated reports but don't even have enough knowledge of how to create them, they probably don't really use the reports anyways. We used to run a whole set of batch reports every night and distribute to all the managers, what a waste of paper that was.
How true that is... I am sure we have all had a client like that.
Could you please show me some sample code on how to open a Crystal report using Navision code (Automation objects).
I DO NOT WISH TO USE HYPERLINK!!
Thank you
Jorgito
Please help us how to Open Crystal Report within Navision (we don't want to use hyperlink). Anyone know how to create objects inside navision using crystal report?
thanks,
archaingels
SHELL('C:\Program Files\Crystal Decisions\Crystal Reports 9\crw32.exe m:\daily\EditList.rpt');
where m:\daily\editlist.rpt is the report name
I think the real question is how do we pass parameters into a Crystal Report from Navision.
NOT - we don't want to use Hyperlink!
I still haven't found the time to try it out.
It seems to me that if you create Parameter fields(Variables) in Crystal and assign them to the fields in the Select Export, then on running the report - the user will be asked to fill in code, texts, dates or whatever.
It's not rocket science. What's the real time savings here?
I guess if you had a customer report and while on the customer card you click a button and the report is run for THAT customer - sounds great!! But using shell or even better hyperlink & parameter fields all the user has to do it type in the customer #.
http://www.BiloBeauty.com
http://www.autismspeaks.org
I am using crystal viewer to open the reports, but it will only let you pull saved data.
does anyone have any suggestions on how to view crystal reports that allows the user to set their own parameters?
Just an update: I found a better way
http://www.mibuso.com/forum/viewtopic.php?t=23298
If you need help with Creating Parameter fields in Crystal let me know.
http://www.BiloBeauty.com
http://www.autismspeaks.org
we also get the same problem of data type.
We arr suscessfully run the crystal report 8.5 from navision as it have ocx control support.
From crystalreport 9 to 2008 there is no ocx control for it.
crystal report above 9 to 2008 can be open through .net but not opened in navision.
I know how to do parameters, its that when you are using crystal viewer, it wont let you use the parameter. I want to let users input parameters, but i dont want to install crystal reports on all their machines, cause i dont want them to have access to the editor, i just want them to use the report and be able to select date ranges.
make more sense?
Everyone has Crystal Installed on teir machines. I simply click File->Report Options->Read Only - to stop any modifing of reports.
I know that if they play around with crystal enough they might find that checkbox. So it's not 100 effective but nobody's found it yet 8) and I'm not really worried if they did. I have copys of all the reports in case someone messes 1 up.
I see a bunch of automation & ocx controls but I never needed to play with them. If someone would post how to just open 1 with ocx or dll I'd like to see that too.
I think I went the route of the Executing table
http://www.mibuso.com/forum/viewtopic.php?t=23298
was that don't you need to use up a Nav report to execute a CR report.
Since we have only 100 I didn't want to use any just to access a crystal report.
http://www.BiloBeauty.com
http://www.autismspeaks.org
Does anyone have solution for this?
Calling Crystal in Navision with passing parameters?
Can anybody share the coding?
Appreciate it.
Rodel
Australia
Pressure is an opportunity.
i need it so bad.
THanks in advance
To start the report from RTC or Classic is not a big problem. The problem is to pass parameters to that report.
So , i found/made the solution :
I made an program that will pass the parameters to report. From NAV i execute the program with parameters ... then everything works like a charm.
Here is the steps to make it done :
1. Download this application : https://rapidshare.com/files/154355060/report.zip
2. copy the report.exe from that zip to Classic and RTC folder
Ex:
C:\Program Files\Microsoft Dynamics NAV\60\RoleTailored Client
and C:\Program Files\Microsoft Dynamics NAV\60\Classic
This have to be done on every client.
3. Open report.exe and set the path where the Crystal reports files are located (i recommend a network path). Then close the application report.exe
4. NAV report setup :
Create a new report.
Set these Globals :
Name / Data Type / Subtype / Length
Vbs / OCX / ScryptControl Object /
code1 / text / / 250
tctCR / text / / 30
params/ text / / 250
Select the DataItem ( Ex: Sales Invoice Header - for a invoice)
The code
Hope that helps.
I couldn't open report.exe file. I'm getting the attached screen.
If I say No nothing happening, If I say Yes it's taking me to Visual Studio.
Please advise!
Thanks in advance
Solved
Just follow the download available here in this link
http://mibuso.com/dlinfo.asp?FileID=1415
can you please explain a bit more the following:
I am trying to use Crystal Reports in Navision. Just came here while searching the forum
can you please tell me how to use SHELL?
I am trying like this with no luck
SHELL('C:\Program Files\SAP BusinessObjects\SAP BusinessObjects Enterprise I 4.0\win32_x86\crw32.exe C:\Report1.rpt');
and getting attached error message
Thanks in advance
But the main thing is to send parameters to Crystal Reports.
when I am trying the following code, am getting this error:
An exception was raised in method Executestatement. The OLE Control ot Automation server has returned error (HRESULT) -2147352567
I have been to other post and found COMDLG32.OCX was missing. I have registered it with custom controls with same error coming up ](*,)
I spend lot of time on this issue to send parameters to crystal reports from Navision.
can some one please help me out ?
Thanks