Liquid UI - Documentation - 6.04.05.01 JScreen

6.04.05.01 JScreen


The JScreen object is used to create a new Offline screen object. Screen objects are used to represent Offline screens. The syntax to create a new screen is as follows:

objScreen = new JScreen( ); 


The object takes several methods, which are listed below.

SetCaption

The SetCaption, method applies a caption to the screen. The syntax is as follows:

void JScreen.SetCaption(strCaption,strDynProName,strDynProNumber);

An example is shown below:

objScreen.SetCaption("Create Sales Order","SAPMV45A","0100"); 


SetLanguage

The SetLanguage method specifies the default language to be used by the screen. The syntax is as follows:

void JScreen.SetLanguage(strLanguage); 

An example is shown below:

objScreen.SetLanguage("en"); 


SetWindowPosSize

The SetWindowPosSize method specifies the screen's window size and position. The syntax is as follows:

void JScreen.SetWindowPosSize(iTop,iLeft,iBottom,iRight); 

An example is shown below:

objScreen.SetWindowPosSize(1,0,50,80); 


GetWindowPosSize

The GetWindowPosSize method captures the window size and position of a screen object. The syntax is as follows:

void JScreen.GetWindowPosSize( ); 

An example is shown below:

objScreen.GetWindowPosSize( ); 
the format of strPosition is "top,left,bottom,right"


CreateLabel

The CreateLabel method creates a label control on the screen. The syntax is as follows:

void JScreen.CreateLabel(iType,strLabel,iRow,iCol,strFieldName); 

An example is shown below:

objScreen.CreateLabel(1,"label",10,13,"field name"); 


CreateEdit

The CreateEdit method creates a new edit control on a screen. The syntax is as follows:

void JScreen.CreateEdit(iType,strLabel,iLabelRow,iLabelCol,iEditRow,iEditCol,iEditWidth,strFieldName);

An example is shown below:

objScreen.CreateEdit(1,"label",3,13,3,20,8,"field_name");


CreatePushButton

The CreatePushButton method, as one would suspect, creates pushbuttons on a screen. The syntax is as follows:

void JScreen.CreatePushButton(iType,strLabel,iRow,iCol,iEditRow,iWidth,iHeight,strFieldName,strCode); 
void JScreen.CreatePushButton(iType,strLabel,iRow,iCol,iEditRow,iWidth,iHeight,strFieldName,strCode);

An example is shown below:

objScreen.CreatePushButton(1,"label",3,13,3,20,"field_name","=COMMAND"), 


CreateCheckbox

The CreateCheckbox method creates checkboxes on a screen. The syntax is as follows:

void JScreen.CreateCheckbox(iType,strLabel,iRow,iCol,iEditRow,iWidth,iHeight,strFieldName,strDefault,strFcode);

An example is shown below:

objScreen.CreateCheckbox(1,"label",3,13,3,20,"field_name","X","=COMMAND"),


CreateRadioButton

The CreateRadioButton method creates radio buttons on a screen. The syntax is as follows:

void JScreen.CreateGroupBox(iType,strLabel,iRow,iCol,iWidth,iHeight,strFieldName); 

An example is shown below:

objScreen.CreateRadioButton(1,"label",3,13,3,20,"field_name","X","=COMMAND"), 


CreateGroupBox

This method creates a new group box control on the screen. The syntax is as follows:

void JScreen.CreateGroupBox(iType,strLabel,iRow,iCol,iWidth,iHeight,strFieldName); 

An example is shown below:

 objScreen.CreateGroupBox(1,"label",3,13,3,20,"field_name");

 

CreateTableControl

This method creates a new table control on the screen. The syntax is as follows:

void JScreen.CreateTableControl(objListControl,bIsTble); 

An example is shown below:

objScreen.CreateTableControl(objListControl,true); 


AddFunctionKey

This method adds a system function key into the screen. The syntax is as follows:

void JScreen.AddFunctionKey(iKeyID,strToolTip); 

An example is shown below:

objScreen.AddFunctionKey(1,"tool tip"); 


AddApplicationKey

This method adds an application key into the screen. The syntax is as follows:

void JScreen.AddApplicationKey(iKeyID,strLabel,strToolTip); 

An example is shown below:

objScreen.AddApplicationKey(1,"label","tool tip"); 


Send

This method sends a screen. The syntax is as follows:

void JScreen.Send(strMessage,iBeepType);

An example is shown below:

objScreen.Send("message",1); 


SendLogOffPackage

This method sends the logoff package. The syntax is as follows:

void JScreen.SendLogOffPackage( ); 

An example is shown below:

objScreen.SendLogOffPackage( ); 


SetElementValue

This method sets a value for a given screen element. The syntax is as follows:

void JScreen.SetElementValue(strFieldName,iType,strValue); 

An example is shown below:

objScreen.SetElementValue("field",2,"value"); 


GetElementValue

This method returns the value of a given screen element. The syntax is as follows:

void JScreen.GetElementValue(strFieldName,iType,strValue);


An example is shown below:

strValue = objScreen.GetElementValue("field",2); 


FindTableListControl

This method is used to find a table or a list control in a given screen. The syntax is as follows:

JScreen.FindTableListControl(iTop,iLeft);

An example is shown as follows:

objTableControl = objScreen.FindTableListControl(1,2); 


FindFocusedControl

This method is used to find a focused control on a given screen. The syntax is as follows:

JScreen.FindFocusedControl( );

An example is shown below:

objControl = objScreen.FindFocusedControl( ); 


GetTCode

This is used to find the transaction code of a given screen. The syntax is as follows:

JScreen.GetTCode( ); 

An example is shown below:

strTCode = objScreen.GetTCode( );

 

GetEventType

This method is used to get the event type in a returned screen. The syntax is shown below:

JScreen.GetEventType( ); 

An example is as follows:

strEventType = objScreen.GetEventType( ); 


GetEventCode

This method is used to get the event code in a returned screen,. The syntax is as follows:

JScreen.GetEventType( ); 

An example is shown below:

strEventType = objScreen.GetEventCode( );


CleanContents

This method is used to clean the contents of a given screen. The syntax is as follows:

JScreen.CleanContents( ); 

An example is shown below:

objScreen.CleanContents( ); 


GetVScrollPos

This method gets the vertical scroll positions of a table or list control on a given screen. The syntax is as follows:

 JScreen.GetVScrollPos( ); 

An example is shown below:

objScreen.GetVScrollPos( ); 


MergeInputStream

This method merges the incoming input stream into the system main modal. The syntax is as follows:

JScreen.MergeInputStream( );

An example is shown below:

objScreen.MergeInputStream( ); 


AddScreen

This method adds a screen object on top of the current screen. The syntax is as follows:

JScreen.AddScreen( );

An example is shown below:

objScreen.AddScreen( );

 

RemoveTopScreen

This method removes the top screen object added by the AddScreen method. The syntax is as follows:

JScreen.RemoveTopScreen( ); 

An example is shown below:

objScreen.RemoveTopScreen( ); 

 


Can't find the answers you're looking for?