Step 3 of 4: Adding a Grid

In this step you will add a grid that will be used to display the data in the Categories table of the Northwind database. You can use C1FlexGrid or any grid you are familiar with, but in this example, we'll use a DataGridView control.

1.   Drag a DataGridView control from the Toolbox onto your form.

2.   Click the DataGridView's smart tag and set the DataSource to the c1DataSource1 control we added to the form.

 

 

3.   In the Visual Studio Properties window, set the DataMember property to Categories. The grid will automatically generate columns for all the fields in the Categories type.

Now simply run the project to view the grid!


Send us comments about this topic.
Copyright © GrapeCity, inc. All rights reserved.