PreviousNextIndex

Trigger phrase

Defines triggers on one or more user-interface events for a single user-interface component. Use the Trigger phrase within the statement that defines or creates the associated user-interface component.

Note: Does not apply to SpeedScript programming.
Syntax

TRIGGERS: 
  { ON event-list [ ANYWHERE ] 
      {     trigger-block 
         |  PERSISTENT RUN procedure 
              [ IN handle ] 
              [ ( input-parameters ) ] 
      } 
  } ...  
  END [ TRIGGERS ] 

event-list
ANYWHERE
trigger-block
PERSISTENT RUN procedure [ IN handle ] [ ( input-parameters ) ]
Example

This procedure defines triggers for two buttons:

r-trigp.p
DEFINE FRAME cust-frame. 
DEFINE QUERY custq FOR Customer. 
DEFINE BUTTON nextcust LABEL "Next" 
  TRIGGERS: 
    ON CHOOSE DO: 
      GET NEXT custq. 
      DISPLAY Customer WITH FRAME cust-frame. 
    END. 
  END TRIGGERS. 
DEFINE BUTTON prevcust LABEL "Previous" 
  TRIGGERS: 
    ON CHOOSE DO: 
      GET PREV custq. 
      DISPLAY Customer WITH FRAME cust-frame. 
    END. 
  END TRIGGERS. 
OPEN QUERY custq FOR EACH Customer. 
GET FIRST custq. 
DISPLAY Customer WITH FRAME cust-frame. 
ENABLE nextcust AT COLUMN 1 ROW 7 prevcust WITH FRAME cust-frame. 
WAIT-FOR WINDOW-CLOSE OF CURRENT-WINDOW. 

Notes
See also

CREATE widget statement, DEFINE MENU statement, ON statement


OpenEdge Release 10.2B
Copyright © 2009 Progress Software Corporation
PreviousNextIndex