CGridCtrl:SelectSheet, CGridView:SelectSheet


The SelectSheet method selects the grid sheet to be top-most in the CGridCtrl. This method requires the grid to have more than 1 sheet.

Syntax

CGridCtrl:SelectSheet(nTabIndex)

bullet.gif    where nTabIndex is the index of the sheet, between 1 and the number of sheets.

Example

The following script selects tab number 2 to be shown top-most in the grid:

V = attach_gridview()

-- attach a grid on the Mira desktop

G = new_gridctrl(V)

-- create a CGridCtrl for the window

if G:GetNumSheets() > 1 then

-- the grid must have at least 2 sheets

  G:SelectSheet(2)

-- select sheet 2

end

 

Related Topics

CGridCtrl class

GetNumSheets


Mira Pro x64 Script User's Guide, v.8.77 Copyright Ⓒ 2024 Mirametrics, Inc. All Rights Reserved.