9 8 Using an Action Bar From a Function

LANSA Application Design

9.8 Using an Action Bar From a Function

When an RDML function that is part of an action bar process is invoked, any screen panel it presents by DISPLAY or REQUEST commands, will have an action bar on its top lines like this (using from 1 to 6 action bar options):

  Action 1  Action 2  Action 3  Action 4  Action 5  Action 6  

______________________________________________________________

            << RDML Function Panel Title >>                    

   

 

or, like this (7 to 12 options):

 

  Action 1  Action 2  Action 3  Action 4   Action 5  Action 6  

  Action 7  Action 8  Action 9  Action 10  Action 11 Action 12 

_______________________________________________________________

                << RDML Function Panel Title >>                 

    

 

or even like this (13 to 18 options):

 

  Action 1  Action 2  Action 3  Action 4  Action 5  Action 6  

  Action 7  Action 8  Action 9  Action 10 Action 11 Action 12 

  Action 13 Action 14 Action 15 Action 16 Action 17 Action 18 

_________________________________________________________________

                 << RDML Function Panel Title >>                 

   

 

Some things that should be noted about executing an RDML DISPLAY or REQUEST command within an action bar process are:

  • You cannot stop the action bar from appearing.
  • Pull down Choices may be unavailable. The availability or unavailability is established from the action bar control table (initially) and then controlled by invoked RDML functions by using the SET_ACTION_BAR built in function.
  • The Exit function key will be enabled from the EXIT_KEY parameter of the DISPLAY or REQUEST command that presented the panel and action bar and handled normally.
  • The Cancel function key will be enabled from the MENU_KEY parameter of the DISPLAY or REQUEST command that presented the panel and action bar and handled normally.
  • The switch (to action bar or from action bar) function key is always enabled and cannot be suppressed. If the cursor is above or on the action bar separator line when the switch key is used, it is taken as "switch to panel body", if it is below the separator line, it is taken as "switch to action bar".
  • The user cannot be stopped from switching to the action bar and altering the flow of control into another RDML function without the "active" RDML function ever regaining active control.
  • The previous point brings the first touch of the "non-procedural" component of action bar processing. When an RDML function executes a DISPLAY or REQUEST command, it may never regain control back from the screen panel, because the user has caused it to terminate and then activated another RDML function.
  • This is an important point to consider when including calls to other functions. If a screen panel is displayed from a called function the user has the opportunity to return to the action bar and re-select the original function. This would cause a recursive call error.
  • This non-procedural flow of control means that a different style of application design and programming techniques may be required. Action bar functions tend to be very small, highly independent and able to work "standalone" (ie: without ever relying on another function).
  • Action bar functions often appear to be "endless loops", which just perform one simple action again and again, waiting for the user to alter the flow of control into some other function.
  • As a result of the amount of control that the user is given, action bar functions tend to have very little "hard coded" flow of control logic (such as function key handling).