Failed to open a rowset Crystal reports

I have created a crystal report on my local windows application.  I used the  crystal wizard and got the parameters needed.

when I ran the report in the viewer I get this error

Failed to open a rowset  

this is all i used for code

 Dim rpt As New report1
CrystalReportViewer1.ReportSource = rpt

p.s. the database is not local


I bought the crystal report book and followed the directions but still can't get it working

Who is Participating?
cyberdevil67Connect With a Mentor Commented:
the exact commands are

                Report.SetDatabaseLogon("username", "password")
                Report.SetParameterValue("CompanyCode", thisCompanyCode)
                Report.SetParameterValue("StartingInvoice", thisInvoice)
                Report.SetParameterValue("Reprint", True)
                Report.SetParameterValue("IsBranch", False)
                Report.SetParameterValue("PrintDiscount", False)
Hi genesisproject,

 is rpt.Load() loading your report? You might need to look at this

 Dim report as ReportDocument = new ReportDocument()
 CrystalReportViewer.ReportSource = report

 Also if you have paramters you might need to also look at

 DatabaseLogin or is it Logon and SetParameters

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.