The Grids object can be used to create, get or edit the grid in Maxsurf. It does not support the space function (to distribute grid lines) that can be used from inside of Maxsurf, but does support all other aspects.

Figure 4 Grids Object Hierarchy
The code to access these objects and methods is:
msApp.Design.Grids.AddGridLine msGTButtocklines, _
Butt_01, 4, 0
i = msApp.Design.Grids.LineCount msGTButtocklines
See Also:
Tutorial Part 3: Creating a Grid on page 30
Grids Object on page 40