wasabi3689
asked on
How to pop up frm-40301 when the form is empty
I am using Oracle 8i and application version is 11.0.300.
I have a form, when I query the form from menu (query->enter) and input a ID, if the ID return nothing, I want the following message popped up on the tool bar
frm-40301:query caused no record to be retrieved. Re-enter
but, now if empty form, it still have the following in the tool bar
Enter a query; please Ctrl+F11 to execute, F4 to Cancel
How to fix it?
I have a form, when I query the form from menu (query->enter) and input a ID, if the ID return nothing, I want the following message popped up on the tool bar
frm-40301:query caused no record to be retrieved. Re-enter
but, now if empty form, it still have the following in the tool bar
Enter a query; please Ctrl+F11 to execute, F4 to Cancel
How to fix it?
ASKER
I created on-message trigger and put it in either form level or block level or both, still doesn't work. When I query an ID with empty form, still show
"Enter a query; please Ctrl+F11 to execute, F4 to Cancel"
My on-message trigger, just one line
exit_form;
"Enter a query; please Ctrl+F11 to execute, F4 to Cancel"
My on-message trigger, just one line
exit_form;
On-Message trigger ought to be like this:
if message_code = 40301 then
null; -- this suppress the message: "frm-40301:query caused no record to be retrieved. Re-enter"
end if;
But this message:
"Enter a query; please Ctrl+F11 to execute, F4 to Cancel"
seems to be your message when invoking enter-query mode.
if message_code = 40301 then
null; -- this suppress the message: "frm-40301:query caused no record to be retrieved. Re-enter"
end if;
But this message:
"Enter a query; please Ctrl+F11 to execute, F4 to Cancel"
seems to be your message when invoking enter-query mode.
ASKER
I tried it, still doesn't work
I add on-message to either form level or block level (for the form) or both, when I enter query mode (query->enter, then query->run), it still have the same message "Enter a query; please Ctrl+F11 to execute, F4 to Cancel", never change to "frm-40301:query caused no record to be retrieved. Re-enter" when queried an empty form.
In my on-message trigger, I have following
if message_code = 40301 then
null;
end if;
I add on-message to either form level or block level (for the form) or both, when I enter query mode (query->enter, then query->run), it still have the same message "Enter a query; please Ctrl+F11 to execute, F4 to Cancel", never change to "frm-40301:query caused no record to be retrieved. Re-enter" when queried an empty form.
In my on-message trigger, I have following
if message_code = 40301 then
null;
end if;
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
exit_form;
built-in.
If you want to suppress that message then you can use On-Message trigger (on form level) and write there something like this:
if message_code = 40301 then
null;
end if;