Crystal Reports Logon failed

K

kimberly.walker

Im creating a report in the .net 2003 and using sql server 2000 Ive
checked all the help topics and even the support in microsoft my
problem is I still keep getting the error Logon failed when i try to
run a report. Below is my code: Any help will be greatly
apprecated...

ConnectionInfo cnn = new ConnectionInfo();
TableLogOnInfo crTableInfo = new TableLogOnInfo();
CrystalReport1 crp = new CrystalReport1();

foreach(CrystalDecisions.CrystalReports.Engine.Table crtable in
crp.Database.Tables)
{
crTableInfo = crtable.LogOnInfo;
if (crtable.Name == "tblTroubleTickets")
{ crTableInfo.ConnectionInfo.ServerName = "FSQLNV";
crTableInfo.ConnectionInfo.DatabaseName = "JEHelp";
crTableInfo.ConnectionInfo.UserID = "walk";
crTableInfo.ConnectionInfo.Password = "98HElp!";
}
else
{
crTableInfo.ConnectionInfo.ServerName = "FSQLNV";
crTableInfo.ConnectionInfo.DatabaseName = "JEHelp";
crTableInfo.ConnectionInfo.UserID = "walk";
crTableInfo.ConnectionInfo.Password = "98HElp!";
}
crtable.ApplyLogOnInfo(crTableInfo);
if(!crtable.TestConnectivity())
Console.WriteLine(crtable.Name);
}
CrystalReportViewer1.ReportSource = crp;
 
A

Andrew Robinson

I haven't used Crystal in a long time and have no plans on using it in the
future but have some vague memories that the server field is really the dsn
name for an ODBC entry. Not well documented and poorly implimented.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,969
Messages
2,570,161
Members
46,709
Latest member
AustinMudi

Latest Threads

Top