Wednesday, May 30, 2018

custom ON-ERROR And ON-MESSAGE On Oracle forms

At Forms Level 
create tow Trigger

1-ON-ERROR 

declare
     errnum number := ERROR_CODE;
     errtxt varchar2(80) := ERROR_TEXT;
     errtype varchar2(3) := ERROR_TYPE;
     field_name varchar2(30);
begin

     field_name := substr(:SYSTEM.TRIGGER_ITEM ,instr(:SYSTEM.TRIGGER_ITEM ,'.') + 1);
     message( 'ERROR ' || field_name || ': ' ||errtxt); message( 'ERROR ' || field_name || ': ' ||errtxt);
     display_error;
     raise form_trigger_failure;
     end;

2-ON-MESSAGE

DECLARE
  lv_errtype VARCHAR2(3)  := MESSAGE_TYPE;
  lv_errcod NUMBER        := MESSAGE_CODE;
  lv_errtxt VARCHAR2(80)  := MESSAGE_TEXT;
BEGIN
  IF lv_errcod = 40400 THEN
     Message('saved Successfully'); Message('saved Successfully');
 -- ELSIf lv_errcod in(42100) Then
    --null;
 ELSIF lv_errcod IN( 42100 ) AND lv_errtype='FRM' THEN
  NULL;
 ELSE
 
    Message(lv_errtype||'-'||to_char(lv_errcod)||':  '||lv_errtxt);
    Message(lv_errtype||'-'||to_char(lv_errcod)||':  '||lv_errtxt);
  END IF;
END; 

1 comment:

  1. Cielo columbia titanium | TITanium Art | TITanium Art
    Cielo columbia titanium by dewalt titanium drill bit set TITanium Art titanium plate flat iron - TITanium Art. Designed with titanium hammer stunning features and a wide palette, Cielo Columbia is crafted titanium industries in the $59.99 · titanium i phone case ‎In stock

    ReplyDelete

signer information does not match signer information of other classes in the same package in Oracle forms java bean

The Main issue to this , is there are many jar File have same package name on it To Solve the issue ,used  JDeveloper or any java develo...