Hi Steven
Assuming you are positioned in the record where you wish to insert ...
select mytable
local lnKey
lnKey = mytable.nKey
replace all nKey with nKey + 1 for nKey >= lnKey
insert into mytable(nKey,cOtherValue) values(lnKey, 'SOME DATA')
Something else that I like to do in this scenario is put a couple of buttons beside the grid, that allow the user to move a record up or down
by swapping the key values between two records.
>Hi,
>
>To insert a record into a grid, between two records, I found it next to impossible. After many hours of work, I found that I had to delete all index tabs, then insert the record, and then re-create the indexes. This is very cumbersome, and dangerous.
>
>Any easier solutions, anyone ?
>
>Regards,
>
>Steve.