Logon failed in ASP.NET

60 pts.
Tags:
ASP.NET
ASP.NET 2.0
C#
Crystal Decisions
Crystal Reports
Web development
hi , i m new in asp.net 2.0 with C#, i have some logon failed problem when exporting crystal report to pdf . code mention below ******************************* CrystalDecisions.Shared.TableLogOnInfo table = new CrystalDecisions.Shared.TableLogOnInfo(); CrystalDecisions.Shared.TableLogOnInfos tables = new CrystalDecisions.Shared.TableLogOnInfos(); CrystalDecisions.Shared.ConnectionInfo connn = new ConnectionInfo(); connn.ServerName = "10.3.1.178"; connn.UserID = "sa"; connn.Password = "sa"; connn.DatabaseName = "perdb"; ReportDocument rpt = new ReportDocument(); rpt.Load(Server.MapPath("birthday.rpt")); table.ConnectionInfo = connn; table.TableName = "#temp"; tables.Add(table); CrystalReportViewer1.LogOnInfo = tables; CrystalDecisions.Shared.ExportOptions expoption = new CrystalDecisions.Shared.ExportOptions(); CrystalDecisions.Shared.DiskFileDestinationOptions diskoption = new CrystalDecisions.Shared.DiskFileDestinationOptions(); string expfile; //expfile = "C:\Documents and Settings\Administrator\My Documents\mysite\birthday.rpt"; expfile = "C:\birthday.pdf"; diskoption.DiskFileName = expfile; expoption = rpt.ExportOptions; expoption.ExportDestinationOptions = diskoption; expoption.ExportDestinationType = ExportDestinationType.DiskFile; expoption.ExportFormatType = ExportFormatType.PortableDocFormat; rpt.SetParameterValue("@month", TextBox2.Text); rpt.SetParameterValue("@locationno", TextBox1.Text); rpt.Export();

Answer Wiki

Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

Discuss This Question:  

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

Thanks! We'll email you when relevant content is added and updated.

Following

Share this item with your network: