Example: sapgui_logon
sapgui_logon logs on to a SAP server.
The following example logs on using the My Connection connection to the R/3 server. My Connection is defined in the SAP client installation. The user name is MyUserName.
Action() {
// Connect to R/3 server, and log on
sapgui_open_connection("My Connection", "con[0]");
sapgui_select_active_session("ses[0]");
sapgui_logon("MyUserName", "MyPassword", "800", "EN", LAST );
// Now you can work
...
return 0;
}