[Originally posted by Marco Silva]

I was in www.freevbcode.com trying some code and it's always appearing a error. I doesn't it work in my computer? See the "split" words , those words causes errors, it says that Method or data member not found, I need some help, please.



Private Sub Form_Load()

' Before modifying the grid's properties, make sure the

' grid is initialized by refreshing the Data control.

Data1.Refresh



' Create an additional splits:

DBGrid1.splits.Add 0 ' Create an additional split



' Hide all columns in the leftmost split, Splits(0),

' except for columns 0 and 1

Dim Cols As Columns, C As Column

Set Cols = DBGrid1.splits(0).Columns

For Each C In Cols

C.Visible = False

Next C

Cols(0).Visible = True

Cols(1).Visible = True



' Configure Splits(0) to display exactly two columns,

' and disable resizing

With DBGrid1.splits(0)