Shooting Blanks

bwgc

Member
Joined
May 20, 2003
Messages
15
Trying to get Crystal Reports to work with Windows forms with a dataset. Heres my form_load event:

sqlDataAdapter1.Fill(dataSet11);

//Pass the dataset to the report
rpt11.Database.Tables[0].SetDataSource(dataSet11.Tables[0]);
crvMain.ReportSource = rpt11;

//Confirm that I have some data...
MessageBox.Show(dataSet11.Tables[0].Rows[0][1].ToString());

...I get a report with headings, but no data.

Anybody???
 
I dont do it the way you have?

But this works for me:

Code:
Dim myReport As ReportClass

myReport = New repWhatEverReport()

myReport.SetDataSource(m_WhatEverDataSet)

Me.CrystalReportViewer1.ReportSource =myReport
 
Actually both methodologies work. The problem was in my report - I had changed datasources and the detail line has disappeared.

But thanks - now I have an alternative!
 
Back
Top