move cursor (next item) to a text item lower in sequence (merged 3) [message #411226] |
Thu, 02 July 2009 09:57 ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
tuckersuz
Messages: 26 Registered: July 2009
|
Junior Member |
|
|
I have a when_validate_item trigger for one of my text items which refers to three previous text item conditions in the code. I have a raise form_trigger_failure at the end, to keep the cursor at that field, so the user cannot move to another field until the correction is made, but I would like the cursor to move to a text item that is above (or earlier in the sequence) than item where the when_validate_item code is.
example:
if (item1 is null) (first in sequence)
and (item2 in 'xxxxx') (5th in sequence)
and (item3 is not null) (7th in sequence) then
message('must enter [value for item1] when item3 is not null');
raise form_trigger_failure;
end if;
end;
I would like the cursor to go BACK to item1, so the user can make the change, instead of resting at item3, where the when_validate_item code is. I know the raise form_trigger_failure is keeping the cursor at item three, since that is where the when_validate_item code is, but I can change that if I can move the cursor to item1, so the user can make the change.
How can I do this?
Many thanks
|
|
|
move cursor (next item) to a text item lower in sequence [message #411227 is a reply to message #411226] |
Thu, 02 July 2009 10:03 ![Go to previous message Go to previous message](/forum/theme/orafaq/images/up.png) ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
tuckersuz
Messages: 26 Registered: July 2009
|
Junior Member |
|
|
How can I move a cursor to an item in an earlier sequence? I have the following code in a when_validate_item trigger:
begin
if item1 is null (first in sequence)
and item2 is not null (seventh in sequence) then
message('item1 cannot be null when item2 is not null');
end if;
end;
I would like the cursor to move to item1. I can keep the cursor at item2 if I use form raise_trigger_failure, but I would rather the cursor move automatically to item1 if the condition is not met, so the user can change it.
many thanks
|
|
|
|
|
|