Share this page

# sapgui_htmlviewer_send_event

General Object Functions

Sends an HTML event.

    int sapgui_htmlviewer_send_event( const char *htmlViewerID, const char *frame, const char *data, const char *url, [args,] LAST ) ;

htmlViewerID | Object ID Strings
frame | The HTML frame
data | Data to be sent
url | The URL
args | Optional Arguments
LAST | A marker indicating the end of the argument list. Not required if Optional Arguments are used.

sapgui_htmlviewer_send_event sends a HTML event.

## 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 example shows the use of sapgui_htmlviewer_send_event.

Copy code

    // Load the sample
    sapgui_set_ok_code("/ndwdm", LAST );
    sapgui_press_button("ENTER", "tbar[0]/btn[0]", LAST );
    sapgui_tree_select_item("Event processing, REPTITLE",
        "shellcont/shell",
        "000733",
        "REPTITLE", LAST );
    sapgui_tree_scroll_to_item("Event processing, REPTITLE",
        "shellcont/shell", "000733", "REPTITLE", LAST );
    sapgui_tree_double_click_item("Event processing, REPTITLE",
        "shellcont/shell", "000733", "REPTITLE", LAST );
    // Get Event
    sapgui_htmlviewer_send_event("usr/cntlHTML_CONTROL/shellcont/shell",
        "",
        "", "sapevent:SUBMIT_FORM_AS_GET_METHOD?FirstName=John&LastName=Smith",
        BEGIN_OPTIONAL,
            "AdditionalInfo=sapgui1029",
        END_OPTIONAL);
        // Post Event
    sapgui_htmlviewer_send_event("usr/cntlHTML_CONTROL/shellcont/shell",
        "",
        "FirstName=John&LastName=Smith",
        "sapevent:SUBMIT_FORM_AS_POST_METHOD",
        LAST );

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