Try OpenEdge Now
skip to main content
ABL Reference
Handle Attributes and Methods Reference : INSTANTIATING-PROCEDURE attribute
 

INSTANTIATING-PROCEDURE attribute

Returns the handle to the procedure in which an object was instantiated.
Data type: HANDLE
Access: Read-only
Applies to: ACTIVE-WINDOW system handle, Asynchronous request object handle, AUDIT-CONTROL system handle, AUDIT-POLICY system handle, BROWSE widget (browse and column), Buffer object handle, Buffer-field object handle, BUTTON widget, Call object handle, Client-principal object handle, CLIPBOARD system handle, CODEBASE-LOCATOR system handle, COLOR-TABLE system handle, COMBO-BOX widget, COMPILER system handle, CONTROL-FRAME widget, CURRENT-WINDOW system handle, Data-relation object handle, Data-source object handle, DEBUGGER system handle, DEFAULT-WINDOW system handle, DIALOG-BOX widget, DSLOG-MANAGER system handle, EDITOR widget, ERROR-STATUS system handle, FIELD-GROUP widget, FILE-INFO system handle, FILL-IN widget, FONT-TABLE system handle, FRAME widget, IMAGE widget, LAST-EVENT system handle, LITERAL widget, LOG-MANAGER system handle, MENU widget, MENU-ITEM widget, Procedure object handle, ProDataSet object handle, Query object handle, RADIO-SET widget, RCODE-INFO handle, RECTANGLE widget, SAX-attributes object handle, SAX-reader object handle, SAX-writer object handle, SECURITY-POLICY system handle, SELECTION-LIST widget, SELF system handle, Server object handle, Server socket object handle, SESSION system handle, SLIDER widget, SOAP-fault object handle, SOAP-fault-detail object handle, SOAP-header object handle, SOAP-header-entryref object handle, Socket object handle, SOURCE-PROCEDURE system handle, Stream object handle, SUB-MENU widget, TARGET-PROCEDURE system handle, Temp-table object handle, TEXT widget, THIS-PROCEDURE system handle, TOGGLE-BOX widget, Transaction object handle, WEB-CONTEXT system handle, WINDOW widget, X-document object handle, X-noderef object handle
When applied to a widget or object handle, this attribute always returns a handle. This handle is either valid or invalid based on the state of the instantiating procedure. The instantiating procedure for a dynamically created object might no longer be running. In this case, the handle is invalid.
Note: Since you can never be sure of the state of an instantiating procedure, never use this attribute as a chained attribute.
In general, INSTANTIATING-PROCEDURE returns the procedure handle for the procedure in which the DEFINE or CREATE statement is executed. Following are the exceptions:
*For a procedure handle or an asynchronous request object handle, INSTANTIATING-PROCEDURE returns the procedure handle for the procedure from which the RUN statement was executed.
*For a socket handle created on a socket server after a CONNECT statement, INSTANTIATING-PROCEDURE returns the procedure handle for the procedure in which the socket server connect procedure is defined.
*For a temp-table handle that is passed from a client to an AppServer, INSTANTIATING-PROCEDURE returns the procedure handle for the first procedure run on the AppServer.
*For a temp-table handle that is received from an AppServer by a client, INSTANTIATING-PROCEDURE returns the procedure handle for the procedure that called the AppServer.
*For implicitly created handles, INSTANTIATING-PROCEDURE returns the procedure handle where the implicitly created object is returned (such as the SAX-attributes object in the StartElement callback).
*For the COM-SELF system handle, which is not a widget handle, INSTANTIATING-PROCEDURE returns a run-time error.
Although this attribute applies to all widgets and handles, not all system handles are associated with an instantiating procedure and do not return a procedure handle. For these system handles, this attribute returns the Unknown value (?). The following system handles always return the Unknown value (?):
CLIPBOARD system handle
CODEBASE-LOCATOR system handle
COLOR-TABLE system handle
COMPILER system handle
DEBUGGER system handle
DSLOG-MANAGER system handle
ERROR-STATUS system handle
FILE-INFO system handle
FOCUS system handle
FONT-TABLE system handle
LAST-EVENT system handle
LOG-MANAGER system handle
RCODE-INFO system handle
SESSION system handle
WEB-CONTEXT system handle