Saturday, May 9, 2015

Top 3 Steps To Suppress Messages Oracle Forms

 Top 3 Steps To Suppress
Messages Oracle Forms 

In the name of Allah, Most Gracious, Most Merciful

Praise be to Allah, blessing and peace be upon our prophet Mohammed, his family and his companions. After that,

During your development process in Oracle Forms,  you may face such common informative &  error messages pop up to you as any programming language.

   No one can remember every ORA- & FRM-  error number and its description. Getting this kind of unhandled messages reflect a bad impression  for the rest of  your work. It is really embarrassing especially when the dead line of your application delivery is getting closer.


    You may find yourself desperate, stressed and  unable to move forward developing the rest of you work smoothly for such annoying nonstop informative and error messages.

ask DefinitionT   
         
    
  Suppress Oracle Forms Informative & Error  Messages


Task Solution:

    Follow the next three steps:


Step One: 


Create a table for customizing Form Errors


CREATE TABLE ERROR_MESSAGES
)
,MSG_CODE NUMBER (5, 0) NOT NULL Primary Key 
,MSG_TYPE VARCHAR2 (1) NOT NULL 
MSG_DESC VARCHAR2 (200) NOT NULL
; ( 


Step Two:


    Run the following Ready Made English Messages Script  as a sample data of such common Oracle Forms Informative & error to run as a script with a bunch of insert statement over Error_Message table that has just created in step no. one.
   

Step Three:


Create On-Message and On-Error Triggers  

DECLARE
       lv_errcod NUMBER  := ERROR_CODE;    
       alert_message          VARCHAR2 (200);
  BEGIN
         SELECT msg_desc
         INTO     alert_message
         FROM   error_messages
         WHERE msg_code = lv_errcod ;
 EXCEPTION
         WHEN OTHERS THEN
       alert_message:=message_type||'-'|| To_Char(message_code)
 || ': ' ||  message_text;
 Raise Form_Trigger_failure;    
  END;

 

Conclusion: 

       You can make a full benefit of the three steps as:
  1.  Create a table to build a database to your form errors.
  2.   Run the following most common customized informative and error messages of The Oracle Forms.
  3. Create an On-Error & On-Message triggers Form-Level to call the customized messages just in need. 




Hope this helps…




Learn More about:






My success only comes from Allah, pls. note your comments and suggestions 
are great help for me in progress thanks in advance.