Ask a Question related to ASP.NET Security, Design and Development.
-
KK #1
Crystal Report security issue
In crystal report I am getting this error.
CrystalDecisions.CrystalReports.Engine : Logon failed.
at .K(String , EngineExceptionErrorID ) at .F
(Int16 , Int32 ) at .E(Int16 ) at
CrystalDecisions.CrystalReports.Engine.FormatEngin e.Export
(ExportRequestContext reqContext) at
CrystalDecisions.CrystalReports.Engine.FormatEngin e.Export
*****Note******
In order to resolve this everybody is recommending to put
security credentials in the code and I did so, still I
have the problem. Looks like my IIS security is giving
trouble. Can any body tell me what I need to cahnge.
Here is the code I am using.
Dim crDoc As ReportDocument
Dim crExp As ExportOptions
Dim crDiskFileDestinationOptions As
DiskFileDestinationOptions
Dim crPath As String
Try
Dim sValue As String
Dim s As String
crDoc = New ReportDocument()
crDoc.Load(Server.MapPath("Mypt.rpt"))
'*****************
Dim crLogonInfo As
CrystalDecisions.Shared.TableLogOnInfo
crLogonInfo = crDoc.Database.Tables
(0).LogOnInfo
crLogonInfo.ConnectionInfo.ServerName
= "MyServer"
crLogonInfo.ConnectionInfo.UserID = "MyId"
crLogonInfo.ConnectionInfo.Password = "welcome"
crLogonInfo.ConnectionInfo.DatabaseName
= "TestDB"
crDoc.Database.Tables(0).ApplyLogOnInfo
(crLogonInfo)
'**********************
crPath = Request.PhysicalApplicationPath
crDiskFileDestinationOptions = New
DiskFileDestinationOptions()
crExp = crDoc.ExportOptions
crDiskFileDestinationOptions.DiskFileName =
crPath + "InvlovedParty.rpt.pdf"
With crDoc.ExportOptions
.ExportDestinationType =
ExportDestinationType.DiskFile
.ExportFormatType =
ExportFormatType.PortableDocFormat
.DestinationOptions =
crDiskFileDestinationOptions
End With
'crDoc.Refresh()
crDoc.Export()
Response.Write("Report File Exported")
Response.Redirect("InvlovedParty.rpt.pdf")
Catch ex As Exception
Response.Write(ex.Source & " : " & ex.Message)
Response.Write("<BR>")
Response.Write(ex.StackTrace)
KK Guest
-
ASP .NET - Crystal Report Error
Hi, I got the following error when I set the report source of the CrystalReportViewer, Can anyone please help me. Thanks...doug. Private Sub... -
ASP.NET Crystal security issue windows server 2003
Hi, The crystal reports viewer for asp.net doesn't work in windows server 2003 when the server is a domain controller. All I get is red exes... -
Pls Hlp : crystal report
Hi, Am getting the following error: cpeaut32 error '800a753c' Invalid enum value. & the code is as follows : set MyParam = ... -
Formatting a Crystal Report
Hi, I have a report that I render out as PDF. I have two sections in my Details section of the report. I want to format the background of... -
ASP + Crystal Report 9
I am beginner on Crystal Report. I want to ask a basic question. How can i display a report in ASP? I search for many web and try the sample...



Reply With Quote

