BoldSignEasily embed eSignatures in your .NET applications. Free sandbox with native SDK available.
’add the handler say in the form’s Load event AddHandler GridListControl1.Grid.QueryCellInfo, AddressOf HandleGridQueryCellInfo ’here is the handler that changes the title of column 1 to "NewTitle" Private Sub HandleGridQueryCellInfo(ByVal sender As Object, ByVal e As GridQueryCellInfoEventArgs) If e.ColIndex = 1 And e.RowIndex = 0 Then e.Style.Text = "NewTitle" ' for col 1 e.Handled = True End If EndSub
> ’add the handler say in the form’s Load event > AddHandler GridListControl1.Grid.QueryCellInfo, AddressOf HandleGridQueryCellInfo > > ’here is the handler that changes the title of column 1 to "NewTitle" > Private Sub HandleGridQueryCellInfo(ByVal sender As Object, ByVal e As GridQueryCellInfoEventArgs) > If e.ColIndex = 1 And e.RowIndex = 0 Then > e.Style.Text = "NewTitle" ' for col 1 > e.Handled = True > End If > EndSub >> >
this.gridDataBoundGrid1.Model.Options.DisplayEmptyRows = true;
3) You should handle Model.QueryColWidth and set the width to a size equal to 1/numCols times teh grid's client width. Here is a sample handler from the GridDataBoundImages sample that support this type of propertional sizing. One last comment is to set grid.SmoothControlResize = false so it draws ok as you size it through its parent.
private void GetColWidth(object sender, GridRowColSizeEventArgs e) { if(this.proportionalCellSizing && e.Index > 0) { e.Size = (int) ((this.gridDataBoundGrid1.ClientRectangle.Width - this.gridDataBoundGrid1.Model.ColWidths[0]) / (float)this.gridDataBoundGrid1.Model.ColCount); e.Handled = true; } }4) set the grid.ListBoxSelectionMode = SelectionMode.One. Also handle, grid.CurrentCellActivating, and in your handler, set e.ColIndex = 0.