CMatrix:ColsUsed
The ColsUsed method returns the maximum number of column members in any row of the CMatrix.
used = CMatrix:ColsUsed() |
On success, this method returns the maximum number of column members in any row.
On failure, this method returns 0.
This method returns the number of columns defined in the row having the most number of columns. This is not the same as the maximum index in any row.
Suppose a CMatrix assigned to M contains 5 members as shown below. There are 2 columns defined in row 50:
|
-- create a CMatrix |
|
-- set member |
|
-- set member |
|
-- set member |
|
-- set member |
|
-- set member |
|
-- result: Used = 2 |
|
-- if finished with M, clean up memory |
Mira Pro x64 Script User's Guide, Copyright Ⓒ 2023 Mirametrics,
Inc. All Rights Reserved.