Try OpenEdge Now
skip to main content
Developing AppServer Applications
Programming ABL Client Applications : Running and managing remote procedures : Understanding proxy procedure handles : Accessing proxy procedure handles
 
Accessing proxy procedure handles
You can obtain access to the proxy procedure handle in the client using the SET option of the RUN statement, which returns the proxy procedure handle value to the HANDLE variable you specify.
You can also access all proxy procedure handles that are currently active for an AppServer connection by returning the value of the FIRST-PROCEDURE attribute or the LAST-PROCEDURE attribute on the server handle for the connection. You can then use the NEXT-SIBLING or PREV-SIBLING attributes on the resulting procedure handle to navigate the list of active proxy procedure handles.
For example:
DEFINE VARIABLE hProxy  AS HANDLE NO-UNDO.
DEFINE VARIABLE hServer AS HANDLE NO-UNDO.

/* Create server handle for hServer and connect to an AppServer. Call remote
persistent procedure on the AppServer. */
hProxy = hServer:FIRST-PROCEDURE. /* First proxy handle */

/* Display the pathname of the file that contains the remote procedure active
on the AppServer for each proxy procedure handle. */
DO WHILE NOT hProxy = hServer:LAST-PROCEDURE:
  DISPLAY hProxy:FILE-NAME.
  hProxy = hProxy:NEXT-SIBLING.
END.
DISPLAY hProxy:FILE-NAME. /* Procedure pathname for last proxy handle */