I have a little VB.net web application which connects to Oracle using ADO.NET so i make connection
Dim Oraclecon As OleDbConnection = New OleDbConnection("Provider=MSDAORA.1;Data Source=name;Password=pass;User ID=name;")
and all work good till i try to use crystal report. it generate exception(it happens when i do report.export) "CrystalDecisions.CrystalReports.Engine.LogOnException: logon failed".
in msdn i found article "Accessing Secure Databases" with such a code:
' Declare require variables.
Dim logOnInfo As New TableLogOnInfo()
Dim i As Integer
' Loop through every table in the report.
For i = 0 To report.Database.Tables.Count - 1
' Set the connection information for current table.
logOnInfo.ConnectionInfo.ServerName = serverNameTxt.Text
logOnInfo.ConnectionInfo.DatabaseName = dbNameTxt.Text
logOnInfo.ConnectionInfo.UserID = userNameTxt.Text
logOnInfo.ConnectionInfo.Password = passwordTxt.Text
report.Database.Tables.Item(i).ApplyLogOnInfo(logOnInfo)
Next i
i suppose servername parameter should be equal Data Source in connection string and DatabaseName should be empty but it still don't work. and frankly speaking i don't understand why crystal report should know logon information if i use in my report ado.net dataset as data source and make connection to oracle through ado.net technology. why should i logon twice?? so if someone had such problems please help any advice will be useful
Dim Oraclecon As OleDbConnection = New OleDbConnection("Provider=MSDAORA.1;Data Source=name;Password=pass;User ID=name;")
and all work good till i try to use crystal report. it generate exception(it happens when i do report.export) "CrystalDecisions.CrystalReports.Engine.LogOnException: logon failed".
in msdn i found article "Accessing Secure Databases" with such a code:
' Declare require variables.
Dim logOnInfo As New TableLogOnInfo()
Dim i As Integer
' Loop through every table in the report.
For i = 0 To report.Database.Tables.Count - 1
' Set the connection information for current table.
logOnInfo.ConnectionInfo.ServerName = serverNameTxt.Text
logOnInfo.ConnectionInfo.DatabaseName = dbNameTxt.Text
logOnInfo.ConnectionInfo.UserID = userNameTxt.Text
logOnInfo.ConnectionInfo.Password = passwordTxt.Text
report.Database.Tables.Item(i).ApplyLogOnInfo(logOnInfo)
Next i
i suppose servername parameter should be equal Data Source in connection string and DatabaseName should be empty but it still don't work. and frankly speaking i don't understand why crystal report should know logon information if i use in my report ado.net dataset as data source and make connection to oracle through ado.net technology. why should i logon twice?? so if someone had such problems please help any advice will be useful