Example 3: Pass a dialog object to a function

 FUNCTION input_customer()
   DEFINE custid INTEGER
   DEFINE custname CHAR(10)
   INPUT BY NAME custid, custname 
     BEFORE INPUT
       CALL setup_dialog(DIALOG)
   END INPUT
 END FUNCTION

 FUNCTION setup_dialog(d)
   DEFINE d ui.Dialog 
   CALL d.setActionActive("print",user.can_print)
   CALL d.setActionActive("query",user.can_query)
 END FUNCTION