>Hi Cetin
>
>Been trying to get the edit grid class to limit the number of lines in the grid. I've tried putting stuff in the AfterRowColumn change to count how many I have on my grid, if theres say 25 I want to not allow any more to be added, but allow the user to edit the least line or previous lines.
>
>Can you point me in the right direction?
>
>Best Regards
>
>Robin
For a quick implementation you could use AfterRowColChange :
lParameters nColIndex
with this
if !mdown() and lastkey() = 145 ;
and !(.lValidate and !evaluate(.cValidation)) ;
and reccount()=25
keyboard '{SPACEBAR}'
inkey()
endif
endwith
dodefault(nColIndex)
PS:Not tested - off the top of my head.
Cetin