0 Replies Latest reply on Feb 21, 2013 4:15 PM by user_anumoses

    Oracle forms when-validate-trigger

      Forms [32 Bit] Version (Production)
      Oracle9i Enterprise Edition Release - 64bit Production
      With the Partitioning, OLAP and Oracle Data Mining options
      JServer Release - Production
      Oracle Toolkit Version (Production)
      PL/SQL Version (Production)
      Oracle Procedure Builder V10. - Production
      PL/SQL Editor (c) WinMain Software (www.winmain.com), v1.0 (Production)
      Oracle Query Builder - Production
      Oracle Virtual Graphics System Version (Production)
      Oracle Tools GUI Utilities Version (Production)
      Oracle Multimedia Version (Production)
      Oracle Tools Integration Version (Production)
      Oracle Tools Common Area Version
      Oracle CORE     Production

      I have a field called equip_code. has list of values
      once the value is chosen I have this code

      if :parameter.EQUIP_USED_OTHERDRIVE is null then     

      case msgbox.show('Equip Code ', 'Equipment selected currently being used on drive - '
           ||chr(10)||'Please verify and contact Supervisor.'
      ||chr(10)||'Are you sure you want to continue?'
      ||chr(10)||'If Yes please enter comments in the comment box','note','NO', 'YES')
      when ALERT_BUTTON2 then
      :parameter.EQUIP_USED_OTHERDRIVE := 'Y';

      l_timer := Create_Timer('Nav_Timer2', 1, NO_REPEAT);

      when ALERT_BUTTON1 then

      :parameter.EQUIP_USED_OTHERDRIVE := 'N';
      :qc_equipment_used2.equip_code := null;
           :qc_equipment_used2.equip_DESC := NULL;( at this point they can re-choose the equipment)
      end case;
      End if;

      if :parameter.NON_ASSIGNED_EQUIP_CODE is null then

           case msgbox.show('Equip Code', 'Equip Code - '||:qc_equipment_used2.equip_code
                          ||' Chosen is not assigned to your department.'
                          ||chr(10)||'Are you sure you want to Continue?'
                          ||chr(10)||'If Yes please enter comments in the comment box', 'note', 'NO', 'YES')
           when ALERT_BUTTON2 then
           :parameter.NON_ASSIGNED_EQUIP_CODE := 'Y';

      l_timer := Create_Timer('Nav_Timer3', 1, NO_REPEAT);

           when ALERT_BUTTON1 then

           :parameter.NON_ASSIGNED_EQUIP_CODE := 'N';
      :qc_equipment_used2.equip_code := NULL;
           :qc_equipment_used2.equip_DESC := NULL;
      End case;

      in my code for when-timer-expired I have this code

      IF ( Get_Application_Property(Timer_Name) = 'NAV_TIMER2' ) THEN
      If :parameter.EQUIP_USED_OTHERDRIVE = 'Y' then
      End if;
      ELSIF ( Get_Application_Property(Timer_Name) = 'NAV_TIMER3' ) THEN
           If :parameter.NON_ASSIGNED_EQUIP_CODE = 'Y' then
           End if;
      END IF;

      What I need here is one message fires and then open the comment box that is there in the when-timer-expired.
      Whats happening is the first message fires and does not go to the comment box. but the second message fires and then the first comment box opens. so go_item('qc_equipment_used2.comments'); fires here . But the second comment box does not come. go_item('qc_equipment_used2.V_EQUIP_USED_COMMENTS'); does not fire.

      I want the message and when user acknowledges, I want the go-item to fire.
      May be a way in when-timer-expired let the when-validate-item trigger fire again after the first message is acknlowledged and comment box is closed and then the second message comes up and then go-item fires.Any help is appreciated.