this is my proplem step by step :
1- I created many crystal reports with many parameters and formula fields on VS2010 IDE
2- And the connection of my crystal reports was assinged to them at desing time , and the SQL query was also generated at the design time (so i dont want to make new dataset at runtime and set crystal report datasource to it).
3- when i try to show the crystal report at run time by this code :
Dim mov As New moves2
'mov is my report
Dim rep As New rep
'rep is the crystal report form
mov.DataSourceConnections.Item(0).SetConnection(DataBasePath, "data.accdb", "", "")
mov.Refresh()
rep.CrystalReportViewer1.ReportSource = mov
rep.CrystalReportViewer1.RefreshReport()
rep.ShowDialog()
mov.Dispose()
rep.Dispose()
a message box “Logon Failed” with an “OK” Button is appearing, when click the “OK” button , every thing work fine and report loads data normally and no proplem !
Now : How to skip this error message because this software will be on clients machines and this message is very annoying and it will seems to clients as error.
Thank you very much and i’am waiting for your solutions .
After About one year of trying and searching on web , i found the solution ! But that was unbelievable , I should give the full path of database in the databaseName parameter ! This is wrong:
This is right :
Thank you.