Loop through textboxes inside datagrid
Posted: Wed Jul 04, 2012 7:30 am
I have a datagrid form that contains a list wherein a user can enter an amount for quantity for each row, i then have a button to let the user save the quantity, for these
i have this code
what i notice though is that my loop only returns a "theControl" object on the datagrid's visible lines, all the other rows doesnt return objects
ex: if the height of my datagrid allows it to show 4 data, the theControl var only returns 4 objects, all controls/rows after that is empty.
Have anyone encountered a similar scenario? and can anyone please let me know in case you have other methods to loop through a datagrid that contains text fields
thanks in advanced,
-Rye
i have this code
Code: Select all
repeat with theLineNo = 1 to the dgNumberOfLines of group "myDgHere"
put the dgDataControlOfLine[theLineNo] of group "myDgHere" into theControl
if fld "quantity" of theControl is not empty then
do something meaningful here...
end if
end repeat
ex: if the height of my datagrid allows it to show 4 data, the theControl var only returns 4 objects, all controls/rows after that is empty.
Have anyone encountered a similar scenario? and can anyone please let me know in case you have other methods to loop through a datagrid that contains text fields
thanks in advanced,
-Rye