Share this page

# sapgui_call_method_of_active_object

Method and Property Functions

Invokes a method of the active object.

    int sapgui_call_method_of_active_object( const char *method_name, char *arg1, ...  char *argn, [optionalArguments,] LAST );

method_name | The name of the SAP method to invoke
arg1..argn | Arguments to the method.
optionalArguments | Optional Arguments
LAST | A marker indicating the end of the argument list. Not required if Optional Arguments are used.

The function sapgui_call_method_of_active_object invokes the method method_name of the current active object selected by sapgui_active_object_from_parent_method or sapgui_active_object_from_parent_property.

args are the arguments that are passed to the control's method. See SAP documentation for discussion of object methods and their arguments.

## Return Values

This function returns LR_PASS (0) on success or LR_FAIL (1) on failure.

## Parameterization

You can parameterize all string (char type) arguments.

## Example

The following call to sapgui_call_method_of_active_object calls the Add function of the current active collection object.

    sapgui_call_method_of_active_object( "Add", "NewString", LAST );

Tips to improve your search results... VuGen Function Reference Version 26.1 Function Reference 26.1 All View Local Help Center View Online Help Center Version: