Home » Developer & Programmer » Forms » frm-40301
frm-40301 [message #78832] Tue, 19 March 2002 03:52 Go to next message
H patel
Messages: 1
Registered: March 2002
Junior Member
Hi

I am working with forms6, i have a tab canvas which has an on-error and on-message trigger to trap informative messages.However when I query my form and there is no data then the message 40301 doesn't appear, i am not trapping this error in the triggers mentioned.Any ideas on how I can bring this message to appear on the console ?

on-message code :
DECLARE
errcode NUMBER(5) := ERROR_CODE;

BEGIN

if errcode = 40405 then
message('Record(s) not saved to database');
end if;


END;
Re: frm-40301 [message #78833 is a reply to message #78832] Tue, 19 March 2002 04:06 Go to previous messageGo to next message
pratap kumar tripathy
Messages: 660
Registered: January 2002
Senior Member
try this

DECLARE
errcode NUMBER(5) := ERROR_CODE;
BEGIN
if errcode = 40405 then
message('Record(s) not saved to database');
else
message(error_text);
end if;
END;
Re: frm-40301 [message #83483 is a reply to message #78832] Wed, 15 October 2003 14:09 Go to previous message
Gabriel
Messages: 11
Registered: February 2001
Junior Member
You have to code an else condition to trap the rest of the messages that you are not trapping, something like this

DECLARE
errcode NUMBER(5) := ERROR_CODE;

BEGIN

if errcode = 40405 then
message('Record(s) not saved to database');

ELSE
/* Leave all other messages unchanged */
MESSAGE( errtype || '-' || TO_CHAR(errcode) || ': ' ||errtext );
END IF;
END;
Previous Topic: Canvas loads up blank
Next Topic: Master Detail form 6.0
Goto Forum:
  


Current Time: Fri Aug 22 01:26:39 CDT 2014

Total time taken to generate the page: 0.11676 seconds