Click here to Skip to main content
15,892,269 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Dear all,


The crystal report ask for login details (ODBC) when deployed on server.

Please assist with a work around.



Thanks
Posted

1 solution

This is a very common question:
CodeProject Quick Answers for "Crystal Reports Login Credentials"[^]

Basically you need to program to set the login information so that it won't prompt.

VB
Dim rd As ReportDocument
rd = New ReportDocument
rd.Load(Server.MapPath("Reports/CrystalReport2.rpt")) 'path to your rpt file

'sql stuff i am using a datatable
Dim dt As DataTable = DataAdaptor.GetDataTable(sql)
dt.TableName = "yourtable"

rd.SetDatabaseLogon(dbloginname;, dbpassword;)
rd.SetDataSource(dt)


Note: This code was taken from Member 2965545[^]'s answer to this question:
Crystal Report asks for Login Credentials[^]
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900