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 ) ;
htmlViewerIDObject ID Strings
frame The HTML frame
data Data to be sent
url The URL
argsOptional 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.

// 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 );