I'm using Visual Studio 2008. I have a form which has a DataRepeater and a ReportViewer displaying a report which uses the same table in the local DataSet that the DataRepeater uses. When I load the form, I fill this table. The DatarRepeater displays the data correctly, but the ReportViewer shows a blank report - and I even have it refresh the report after the table fills.
Here's the load code:
Cheryl dc Kern
Here's the load code:
Code:
Private Sub SNoutput_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim MachineName As String
MachineName = System.Environment.MachineName()
Dim constr As String
constr = My.Settings.M2MAydinOther
Dim SQLstring As String
SQLstring = "SELECT SN, PartRev, Contract, MfrDate, Model, Description, MadeIn, WhichLabel, '*' + SN + '*' AS SNbarcode FROM SerialSNsOut WHERE MachineName = '" & MachineName & "';"
Dim con As System.Data.SqlClient.SqlConnection
con = New System.Data.SqlClient.SqlConnection(constr)
Dim da As System.Data.SqlClient.SqlDataAdapter
da = New System.Data.SqlClient.SqlDataAdapter(SQLstring, con)
da.Fill(LocalInfoTables.SNsOut)
Me.cvLabels.RefreshReport()
End Sub
Cheryl dc Kern