The DataSet can be filled either from a data source or dynamically. ADO.NET enables you to create DataTable objects and add them to an existing DataSet.
vb.netDim dt As New DataTabledataset.Tables.Add(dt)
DataTable dt = new DataTable();dataset.Tables.Add(dt);
A DataTable is defined in the System.Data namespace and represents a single table of memory-resident data. You can set constraint information for a DataTable by using the PrimaryKey and Unique properties. The following ASP.NET program create a DataTable dynamically and add it into a Dataset.
Default.aspx
Untitled Page
Click the following links to see full source code
C# Source Code
VB.NET Source Code
ASP.NET Dataset - Related Contents
Advertisement
ASP.NET Related Topics