Reputation: 1259
I have 7 variables and i need to transfer them in a dataset
I have already create the file with extension .xsd and i have already a report file .rdlc
I see the Dataset "DataTable"in my rdlc file but i can't see any field
It gives me error of "No Dataset is Linked to the document"
From the other hand it sees the dataset in the selection dataset !!!
So at this point I'm completely confused
Please is there anybody which can assist me?
Upvotes: 0
Views: 505
Reputation: 52655
Using a Dataset seems like overkill (you can use anything that is IEnumerable) but if you just want to add a row in a DataSet using code you simiply create an instance and call the Add Method on the Tables Row collection.
Dim ds As TestDS = New TestDS()
ds.YourTableName.Rows.Add(txtInputA.Text,
txtInputB.Text,
txtInputC.Text,
txtInputD.Text,
txtInputE.Text,
txtInputF.Text,
txtInputG.Text
)
Then you can just add it to the DataSources collection
lr.DataSources.Add(new ReportDataSource("Variables", ds))
Upvotes: 1