Try this:
Set Enabled = .F. on every column that you don't what the user to enter (Now there should only be one enabled column left). then put the following code in the textbox control the user can edit.
KeyPress Event:
LPARAMETERS nKeyCode, nShiftAltCtrl
if nKeyCode = 13 or nKeyCode = 9
This.Valid(nKeyCode)
endif
Valid Event:
LPARAMETERS nKeyCode
if nKeyCode = 13 or nKeyCode = 9
if recno('YourGridTable') < reccount('YourGridTable')
KEYBOARD '{DNARROW}'
endif
endif
This code should be enough, it works for me...
/Mårten Törnquist
>>Christian,
>>
>>Set the format and inputmask properties of the textboxes in the column. Also set the column's sparse property to .F.
>
>Jim,
>Yes, this was it. Now, something more difficult (I guess so): When I entered something in a field (in the grid) the focus goes automatically to the next column, even if Tab is .F. for this column. but I want to jump down to the next record, because the user is only allowed to enter one field (column) in the grid.
>Have a solution?
>Thanks to Jar Jar...
---( Mårten Törnquist )---