Crystal reports -pushed data does not show
-
This is driving me mad, two almost identical code segments, one works the other does not. Trying to push data to a Crystal Report The code is ______________________________________________________________________________
private void accessrpt_Load(object sender, System.EventArgs e) { //pass the dataset to the report rpt_log rpt1=new rpt_log(); sqlstring="SELECT STATUS, SITE, START_OF_ROAD, DEPARTED, ARRIVED, END_OF_ROAD, NAME, REASON, ACTION, COMPANY, ROAD_CHECK_REQUIRED, COMMENTS, SITE FROM ARADMIN.TCC_SITE_ARRIVAL_LOG WHERE (NAME = '"+Class1.strVariable +"')"; System.Data.OracleClient.OracleConnection oconn= new System.Data.OracleClient.OracleConnection("user id=hidden;datasource=oracle1;password=hidden"); System.Data.OracleClient.OracleDataAdapter oda= new System.Data.OracleClient.OracleDataAdapter(sqlstring,oconn); oda.Fill(tcc_log1); tcc_log1.WriteXml("c:\\datadump.xml"); rpt1.SetDataSource(tcc_log1); log_rep.ReportSource=rpt1; }
______________________________________________________________________________ I know the dataset is correct - the XML dump is exacly what the SQL requests. But cystal reports pointing to the same dataset (as on the last two lines of the sample above) shows the correct headings, gives no error messages but shows no data. Can anybody suggest where I am going wrong ? Thanks -
This is driving me mad, two almost identical code segments, one works the other does not. Trying to push data to a Crystal Report The code is ______________________________________________________________________________
private void accessrpt_Load(object sender, System.EventArgs e) { //pass the dataset to the report rpt_log rpt1=new rpt_log(); sqlstring="SELECT STATUS, SITE, START_OF_ROAD, DEPARTED, ARRIVED, END_OF_ROAD, NAME, REASON, ACTION, COMPANY, ROAD_CHECK_REQUIRED, COMMENTS, SITE FROM ARADMIN.TCC_SITE_ARRIVAL_LOG WHERE (NAME = '"+Class1.strVariable +"')"; System.Data.OracleClient.OracleConnection oconn= new System.Data.OracleClient.OracleConnection("user id=hidden;datasource=oracle1;password=hidden"); System.Data.OracleClient.OracleDataAdapter oda= new System.Data.OracleClient.OracleDataAdapter(sqlstring,oconn); oda.Fill(tcc_log1); tcc_log1.WriteXml("c:\\datadump.xml"); rpt1.SetDataSource(tcc_log1); log_rep.ReportSource=rpt1; }
______________________________________________________________________________ I know the dataset is correct - the XML dump is exacly what the SQL requests. But cystal reports pointing to the same dataset (as on the last two lines of the sample above) shows the correct headings, gives no error messages but shows no data. Can anybody suggest where I am going wrong ? Thanks