Solved

Oracle Form 5

Posted on 2001-06-30
5
1,625 Views
Last Modified: 2012-06-27
I want to supress the default message 'Do you want to save changes?' in Oracle Form 5. how to do that?

Thanks
Abdul Qadir Khan
0
Comment
Question by:aqk139
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
5 Comments
 
LVL 6

Accepted Solution

by:
M-Ali earned 200 total points
ID: 6241907
When are you getting this message?

For suppressing normal messages in forms, you can set
:SYSTEM.MESSAGE_LEVEL := value

But prompts and vital error messages cannot be suppressed using this.

If you want to clear a form without saving use, CLEAR_FORM(NO_VALIDATE);


Ali
0
 
LVL 2

Expert Comment

by:noriegaa
ID: 6243709
You could also use exit_form(no_validate); or simply exit(no_validate);
0
 

Expert Comment

by:schudasama
ID: 6243965
Hi,

This is how i have done and it works. Create a save button. In the when button_pressed trigger
declare
 al_button number;
 al_id ALERT := find_alert('caution');
begin
 if :global.insertupdateflag = 1 then
   (globally defined variable)
 set_alert_property('caution',alert_message_text,'Do You want to save the changes (Y/N) ?');
 set_alert_button_propert(al_id,alert_button1,label,'Yes');
 set_alert_button_property(al_id,alert_button2,label,'No');
 al_button := show_alert(al_id);
 if al_button = alert_button1 then
   goto commitblock;
 else
   goto endblock;

<<commitblock>>
:global.errcode = 0 then
 commit;
if :global.errcode = 1 then
 goto endblock;
end if;

<<endblock>>
null;

end

here the commitblock is where you are saving the changes. if the errorcode (errcode) is 0 then it will commit otherwise it will go to the endblock and wll not commit the changes.

Hope this will help you.

0
 

Expert Comment

by:schudasama
ID: 6243968
Hi,

This is how i have done and it works. Create a save button. In the when button_pressed trigger
declare
 al_button number;
 al_id ALERT := find_alert('caution');
begin
 if :global.insertupdateflag = 1 then
   (globally defined variable)
 set_alert_property('caution',alert_message_text,'Do You want to save the changes (Y/N) ?');
 set_alert_button_propert(al_id,alert_button1,label,'Yes');
 set_alert_button_property(al_id,alert_button2,label,'No');
 al_button := show_alert(al_id);
 if al_button = alert_button1 then
   goto commitblock;
 else
   goto endblock;

<<commitblock>>
:global.errcode = 0 then
 commit;
if :global.errcode = 1 then
 goto endblock;
end if;

<<endblock>>
null;

end

here the commitblock is where you are saving the changes. if the errorcode (errcode) is 0 then it will commit otherwise it will go to the endblock and wll not commit the changes.

Hope this will help you.

0
 
LVL 2

Expert Comment

by:racher
ID: 6244558
Are you wanting to save and exit or cancel and exit?

Route all exiting via one form procedure
If you want to cancel and exit use EXIT_FORM(NO_VALIDATE) as suggested.
If you want to save and exit use COMMIT;
You may want to hide the messages
40400 : transaction complete: x records applied and saved
40401 : no changes to save
You can do this by putting something in the form on-message trigger that examines the MESSAGE_CODE and then supresses the messages that you want to supress.

Graham
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Truncate is a DDL Command where as Delete is a DML Command. Both will delete data from table, but what is the difference between these below statements truncate table <table_name> ?? delete from <table_name> ?? The first command cannot be …
How to Unravel a Tricky Query Introduction If you browse through the Oracle zones or any of the other database-related zones you'll come across some complicated solutions and sometimes you'll just have to wonder how anyone came up with them.  …
This video shows setup options and the basic steps and syntax for duplicating (cloning) a database from one instance to another. Examples are given for duplicating to the same machine and to different machines
This video shows how to copy an entire tablespace from one database to another database using Transportable Tablespace functionality.

728 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question