CGridView:GetMaxCol
The GetMaxCol method returns the 1-based index of the maximum grid column containing data. For example, suppose a CGridView is created with 20 columns, but the last non-empty column containing data is column 12. In this example, the method returns 12.
nMaxCol = CGridView:GetMaxCol()
Where nMaxCol is the index of the highest column containing data.
On failure, 0 is returned.
The following script returns the index of the last non-empty column containing data:
|
-- attach a grid on the Mira desktop |
|
-- return the 1-based index of the last column |
Mira Pro x64 Script User's Guide, Copyright Ⓒ 2023 Mirametrics,
Inc. All Rights Reserved.