SqlConnection cn=new SqlConnection ("User ID=sa;Initial Catalog=usermod ule;Data Source=NEW5");
SqlDataAdapter da=new SqlDataAdapter (Application["str1"].ToString(),cn) ;
DataSet ds=new DataSet();
da.Fill (ds,"REGISTER,I NOUTDETAILS");
CrystalReport1 cr=new CrystalReport1( );
cr.SetDataSourc e(ds.Tables[0]);
CrystalReportVi ewer1.ReportSou rce=cr;
The above statement represents binding data to crystal reports.
My problem is I am getting error in this statement
cr.SetDataSourc e(ds.Tables[0]);
The error is Invalid table no.
What is the correct statement.
please help me.........
SqlDataAdapter da=new SqlDataAdapter (Application["str1"].ToString(),cn) ;
DataSet ds=new DataSet();
da.Fill (ds,"REGISTER,I NOUTDETAILS");
CrystalReport1 cr=new CrystalReport1( );
cr.SetDataSourc e(ds.Tables[0]);
CrystalReportVi ewer1.ReportSou rce=cr;
The above statement represents binding data to crystal reports.
My problem is I am getting error in this statement
cr.SetDataSourc e(ds.Tables[0]);
The error is Invalid table no.
What is the correct statement.
please help me.........
Comment