Re: FORMS 4.5: FRM-40405 URGENT!!!! HELP NEEDED
Date: 1997/11/28
Message-ID: <19971128013301.UAA02498_at_ladder02.news.aol.com>#1/1
>
>I have got one problem, which I can“t solve.
>Sometimes, I do not find the reason when, Forms Messages appear which
>are very disturbing.
>How can I hide:
>FRM-40400: Transaction complete: <num> records applied and saved
>FRM-40401: No changes to save
>FRM-40405: No changes to apply
>
>I tried to put the commit_form into a if-construct:
>If :system.Block_status in ('changed', 'new' then
> Commit
>End if;
>
>I tried, as said in the manual 'Forms Messages and Codes', to put the
>:system.message_level up to '25', but I fear, this only works for
>informative types not for error types.
>
>
You don't really want to mess with the error message level; you are on the
right track with the on-error trigger. You may hide a real message that you
need to have displayed. The solution we have taken is to put some code in the
on-error trigger. (Be careful of where you put it - on a block or on the form.
Just make sure it does get fired). I don't have it in front of me, but it goes
something like this:
(Ours is a little more extensive - it hides several, and provides more context
sensitive message for several others)
declare
my_err_num integer;
my_err_text varchar2(80);
begin
my_err_num := error_num;
if my_err_num in (40400, 40401, 40405) then
null;
else
<display error message -'FRM- '||to_char(my_err_num)||' '||my_err_txt;
end if;
end;
This masks the error, but the other solution is to see why they are occurring. A very common cause of the 40401 and 40405 messages are if you are doing updates/inserts/deletes on the base table in triggers other than the ON-UPDATE/ON-INSERT/ON-DELETE. Hope this helps
Dan Received on Fri Nov 28 1997 - 00:00:00 CET