I have a simple report (one table and fields) that I have published as a web
service.
A simple ASP.NET web application has only one page with CrystalReportViewer
control on the page.
The report can access the database with the supplied id & password because
at design time I can see the tables & fields in the database.
Basically I'm trying to glean 'where' this log on failure is happening and
there isn't much info forthcoming. The exception is thrown inside of the
crystal reports webservice and isn't readily trappable.
Is this the proper method for specifying the 'log on' info for the report?
or is there a better way?
below are the technical bits
any help greatly appreciated!
TIA,
Rob Pixley
This is the webform code:
Public Class WebForm1
Inherits System.Web.UI.Page
Protected WithEvents CrystalReportViewer1 As
CrystalDecisions.Web.CrystalReportViewer
#Region " Web Form Designer Generated Code "
...
#End Region
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load
Me.CrystalReportViewer1.ReportSource =
"http://localhost/WebService1/GenesisReportService.asmx"
Me.CrystalReportViewer1.LogOnInfo(0).ConnectionInfo.UserID = "user"
Me.CrystalReportViewer1.LogOnInfo(0).ConnectionInfo.Password =
"password"
Me.CrystalReportViewer1.LogOnInfo(0).ConnectionInfo.DatabaseName =
"BFI"
Me.CrystalReportViewer1.LogOnInfo(0).ConnectionInfo.ServerName =
"SUN4"
Me.CrystalReportViewer1.Databind()
End Sub
End Class
The error received is:
Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information
about the error and where it originated in the code.
Exception Details: CrystalDecisions.CrystalReports.Engine.LogOnException:
Logon failed.
Stack Trace:
[LogOnException: Logon failed.]
CrystalDecisions.ReportSource.ProxyReportSource.ThrowExceptionIfError(Respon
seContext response)
CrystalDecisions.ReportSource.ProxyReportSource.GetPage(PageRequestContext
pageReqContext)
CrystalDecisions.Web.ReportAgent.v(Boolean `)
CrystalDecisions.Web.CrystalReportViewer.OnPreRender(EventArgs e)
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Page.ProcessRequestMain()
You can read messages from the Advanced DOTNET archive, unsubscribe from Advanced
DOTNET, or
subscribe to other DevelopMentor lists at http://discuss.develop.com.