Quantcast
Channel: SCN : Discussion List - SAP Crystal Reports, version for Visual Studio
Viewing all articles
Browse latest Browse all 3636

vs2010 executable crashes when calling Crystal report 13.

$
0
0

Hi all i was trying to deploy a program from my server computer to client PC. I can generate the crystal report perfectly fine in my server PC which has vs2010, CRforVS_13_0_8, CRforVS_redist_install_32bit_13_0 all installed. Now that I have my program perfectly running and generating reports exactly as I want I decided to deploy the project. Copied the debug folder of the project after compilation and transfer to one client PC which don't have any Visual studio installed but contains .net framework 4 extended, visual c++ 2005, 2008 redist on those machines. When i click the button that should call/generate the report the exe will just crash and close the program.

 

any help would be much appreciated. Attached is the screenshot of the program after i clicked the button

 

- here is the code i use when calling the report (working perfectly in my server PC)

 

  Dim rep As rptSummary = New rptSummary()

            Dim objdata As New DataTable

            Dim objdr As OleDbDataReader

            Dim txtobj As CrystalDecisions.CrystalReports.Engine.TextObject

 

              myCMDacc.CommandText = "SELECT * FROM tblExpense WHERE Date BETWEEN #" & CDate(lblDateStart.Text) & "# and #" &                  CDate(lblDateEnd.Text) & "# and Division='" & varIdentifier & "' and Expense=TRUE and ORNo<>'PENDING'"

                myCMDacc.Connection = cnSQLacc

 

If cnSQLacc.State = ConnectionState.Closed Or cnSQLacc.State = ConnectionState.Broken Then cnSQLacc.Open()

            objdr = myCMDacc.ExecuteReader

            objdata.Load(objdr)

            rep.SetDataSource(objdata)

            cnSQLacc.Close()

            frmreports.crView.ReportSource = rep

            frmreports.ShowDialog()


Viewing all articles
Browse latest Browse all 3636

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>