Referenced By      Properties       Methods Send us your Feedback
SGColumn Object

Name: SGColumn
Description: SGColumn is object that represents one grid column.
GUID: {F0A68CB2-9109-11D2-8EBB-008048E27A77}

 Show Example
 Copy Code     Show Me

The following example change columns background color. To try the example, place SGGrid and CommandButton control on a form. Paste the code into the Declarations section, press F5 and click button.

Private Sub Command1_Click()
   Dim sgCol As SGColumn
   
   For Each sgCol In SGGrid1.Columns
      sgCol.Style.BackColor = QBColor(sgCol.ColIndex Mod 16)
   Next
   'redraw grid after changing columns
   'background color
   SGGrid1.RedrawEnabled = True
End Sub

Back to topic

Referenced By

SGColumns.Item | SGCell.Column