private void Form1_Load(object sender, EventArgs e)
{
InitializeDataSource();
// The following to lines code can be instead by:
// this.gcMultiRow1.DataSource = studentInfoDataSet.Tables["BasicInfos"];
this.gcMultiRow1.DataSource = studentInfoDataSet;
this.gcMultiRow1.DataMember = "BasicInfos";
// When data binding, the cells in template should be set DataField property to binding a specific column of data source.
this.gcMultiRow1.Template = this.CreateDataBindingTamplate();
this.gcMultiRow1.DataError += new EventHandler<DataErrorEventArgs>(gcMultiRow1_DataError);
}
Private Sub Form1_Load(ByVal sender As Object, ByVal e As EventArgs) Handles Me.Load
InitializeDataSource()
' The following to lines code can be instead by:
' this.gcMultiRow1.DataSource = studentInfoDataSet.Tables["BasicInfos"];
Me.gcMultiRow1.DataSource = studentInfoDataSet
Me.gcMultiRow1.DataMember = "BasicInfos"
' When data binding, the cells in template should be set DataField property to binding a specific column of data source.
Me.gcMultiRow1.Template = Me.CreateDataBindingTamplate()
End Sub