Home » Community » Newbie corner » Grid Ctrl..How to find minimum and maximum element
Re: Grid Ctrl..How to find minimum and maximum element [message #33243 is a reply to message #33234] |
Tue, 19 July 2011 22:48   |
|
You have to manually iterate over cells in a given row, for example:
GridCtrl grid;
int minValue = INT_MAX;
int maxValue = INT_MIN;
int row = 5;
for(int i = 0; i < grid.GetColumnsCount(); i++)
{
int v = grid(row, i);
if(minValue > v)
v = minValue;
else if(maxValue < v)
v = maxValue;
}
|
|
|
Goto Forum:
Current Time: Fri Jul 18 14:42:10 CEST 2025
Total time taken to generate the page: 0.03061 seconds
|