Self

4D - Documentation   Français   English   German   4th Dimension 2004, Command Theme List   4th Dimension 2004, Command Alphabetical List   4th Dimension 2004, Constant Theme List   Back   Previous   Next

version 3


Self Pointer

ParameterTypeDescription
This command does not require any parameters
Function resultPointerPointer to form object (if any) whose method is
currently being executed.
Otherwise Nil (->[]) if outside of context

Description

The Self command returns a pointer to the object whose object method is currently being executed.

Self is used to reference a variable within its own object method. It returns a valid pointer only when it is called from within an object method. It cannot be used in a project method, even when called from an object method. If Self is called out of context, it returns a Nil pointer (->[]).

Tip: Self is useful when several objects on a form need to perform the same task, yet operate on themselves.

Example

See the example for the RESOLVE POINTER command.

See Also

RESOLVE POINTER.


4D - Documentation   Français   English   German   4th Dimension 2004, Command Theme List   4th Dimension 2004, Command Alphabetical List   4th Dimension 2004, Constant Theme List   Back   Previous   Next