Report designer cannot add dataset
Hello !
I want create report in report designer, but at runtime will add datasource Dataset for report. At design time need temporary dataset...
This discussion has been closed.
Hello !
I want create report in report designer, but at runtime will add datasource Dataset for report. At design time need temporary dataset...
Comments
Hello!
From your application, export the DataSet schema (and a couple of test rows) once to an XML file with an XSD schema:
dataSet.WriteXml(‘schema_for_designer.xml’, XmlWriteMode.WriteSchema);In the Designer, select Data -> Add Data Source -> XML database and specify this file, schema_for_designer.xml — all tables and columns will immediately appear in the dictionary.
When actually running the application, clear the temporary XML connection (or register the DataSet using `report.RegisterData(realDataSet, ‘YourName’)` with the same table names) and set `Enabled = true`.