[Migrated content. Thread originally posted on 05 February 2003]
I have found out how to disable cells in a grid i.e. by placingmove event-action-fail to event-action
in a ev-msg-goto-cell event
Then by effectively adding 1 to cursor-y I am able to push the cursor to the first cell on the following grid row
However I cannot see how to exit the grid when I hit the last row.
The folowing is my code whch works as I tab down the grid but stalls when I ht the last row. I would like to to tab out of the grid and place my cursor in the next control. I have tried it with and without the move of event-acton-fail (and event-action-fail-terminate for that matter) on the else statement but with no joy
Main-MS-payments-Gd-Ev-Msg-Goto-Cell.
* Navigate around grid by pushing cursor to next line
* If the current line is the last line push to the next field
if event-data-1 not = 1
inquire Main-MS-paymeth-Gd, last-row nos-pmeths
if nos-pmeths > event-data-2
move event-action-fail to event-action
modify main-ms-paymeth-Gd,
cursor-y = (event-data-2 1)
cursor-x = 1
else
move event-action-fail to event-action
move 50 to control-id
move 4 to accept-control
end-if
end-if
.
Perhaps bizzarly I am attempting to use a grid more for display purposes than editing as it presents data more attractively than rows and addresses issues I have with proportional fonts and titles.
Ideally when enter is pressed I would like to pull data from the grid populate fields outside the grid and edit them there, writing them back once complete, but agan, whilst I can pull and populate I cannot place my cursor into an external field.
Can ayone help?



