Spread for ASP.NET 9.0 Product Documentation > Developer's Guide > Managing Data Binding > Tutorial: Binding to a Corporate Database > Binding Spread to the Database |
Your data set is ready, now you need to add the Spread component to display the data, and provide code to bind the Spread component to the data set.
C# |
Copy Code
|
---|---|
FarPoint.Web.Spread.Model.DefaultSheetDataModel model = new FarPoint.Web.Spread.Model.DefaultSheetDataModel(dbDataSet);
FpSpread1.Sheets[0].DataModel = model;
|
Visual Basic |
Copy Code
|
---|---|
Dim model As FarPoint.Web.Spread.Model.DefaultSheetDataModel = New FarPoint.Web.Spread.Model.DefaultSheetDataModel(dbDataSet) FpSpread1.Sheets(0).DataModel = model |