on 01-27-2010 11:26 PM
Greetings all,
Using VS 2005
CR XI R2 sp6
Code is in ASP.net with VB.net code behind.
Using merge module for sp6 and .msi file to install on IIS server.
Dev box is XP service pack 3
IIS Server OS is Server 2003 R2 standard edition Service Pack 2
Reports run fine if they are using out MS SQL server. Doesn't matter if I run the report localhost at the IIS box or out of IE 7 on my development box. Any report that gets data from our Oracle DB gives the following error:
Failed to load database information. Error in File C:\WINDOWS\TEMP\Arrivals By Date {E4D4AF52-E6B4-4C22-89E9-2FE809C23F8E}.rpt: Failed to load database information.
I have installed CR dev environment on the IIS box to try the reports directly and they work in the CR XI dev environment.
IIS box is upgraded to CR XI R2 sp6.
TNSNAME file is in place and ping tested.
Oracle drivers are installed and tested.
Using the following code to pass user name and password to Oracle.
rpt.DataSourceConnections(0).SetLogon("Test", "TestPass")
It appears to be passing parameters and prompts for the non passed parameters. It seems to blow up ass it goes to get the data for the report.
Merge module I am using is marked CrystalReports11_5_NET_2005.msm, size: 81872. I downloaded it the other day from the download spot here.
I have read all the posts and docs I can find on it and nothing I have found has worked. Any ideas?
Thanks,
Dan...
Edited by: Dan Pearce on Jan 29, 2010 12:10 AM
I'm not 100% clear if this works anywhere for you (dev system?). But the code I have had success with is as follows:
Dim connection As ConnectionInfo
connection = New ConnectionInfo()
With connection
.ServerName = Our Server Name Here
.UserID = Our User ID Here
.Password = Our Password Here
.DatabaseName = Our Database Name Here
.Type = ConnectionInfoType.SQL
End With
Dim CRTableLogOnInfo As TableLogOnInfo
For Each Tbl As Table In Report.Database.Tables
CRTableLogOnInfo =Tbl.LogOnInfo
CRTableLogOnInfo.ConnectionInfo = connection
Tbl.ApplyLogOnInfo(CRTableLogOnInfo)
Tbl.Location = Our Schema Here & "." & Tbl.Location
Next
Ludek
Follow us on Twitter http://twitter.com/SAPCRNetSup
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Ok, I gave that a try and no luck. It does not appear to be a failure in setting the logon information.
I tried removing the rpt.SetDatabaseLogon("test", "test") and got an interesting result. It did not prompt me for the logon info. If I do this on my dev machine it will prompt me for the password. If I run it off the IIS server it does not prompt.
That is implying something. Any ideas?
Thanks,
Dan...
I think it may be a good idea to compare the runtime on the dev box and the deployed box. Modules:
https://smpdl.sap-ag.de/~sapidp/012002523100006252802008E/modules.zip
is a good utility for that. Look at both the CR files and Oracle client files.
Ludek
Ok, found the issue. On the IIS server machine. The worker process for ASP.NET the handles Crystal Reports did not have permissions to read the Oracle directory and the TNSNAMES file buried within. By allowing read permissions to the worker process (in my case NetworkServices) Crystal could now getting the routing information from the TNSNAMES files and it runs just fine.
Thanks all,
Dan...
User | Count |
---|---|
84 | |
10 | |
9 | |
8 | |
6 | |
6 | |
6 | |
5 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.