avSwitch Method

Method: avSwitch

Parameters:

Name Usage Class Description

To

Input - Mandatory

Alpha – max length 32

Specify as one of FRAMEWORK, APPLICATION or BUSINESSOBJECT indicating the object to which control is to be switched.

Named

Input – Optional

Alpha – max length 32

Specifies the User Object Name/Type of the APPLICATION or BUSINESSOBJECT that control is to switch to.

ToObjectNamed

 

Input - Mandatory

Alpha – max length 32

Specifies the User Object Name/Type of the APPLICATION or BUSINESSOBJECT that control is to switch to.

Special values

*SELECT_APPLICATION

*SELECT_BUSINESSOBJECT

*APPLICATION_ABOUT

*FRAMEWORK_ABOUT

may be used

Execute

Input – Optional

Alpha – max length 32

Specify the User Object Name/Type of any command that is to be executed in the target FRAMEWORK, APPLICATION or BUSINESSOBJECT.

ClearInstanceList

Input – Optional

Boolean

Clear the current business object instance list before adding new instances with the avAddSwictInstance method. Specify as TRUE or FALSE (in uppercase) only. Default value is FALSE.

NOTE: This parameter is only effective if new instances are added with the avAddSwictInstance method.

Caller

Input – Mandatory

PRIM_OBJT

Always specify this argument as Caller(#Com_Owner)), unless you are using VLF-ONE and find that Caller(#Com_Owner ) will not compile.

In that case use Com_Owner(#uSystem.MainVLFPanel).

CallerInfo

Input – Optional

Alpha – max length 20

VLF-WIN only. Use this optional argument to provide additional identification information. 

In VLF-ONE programs use CallerReference.

CallerReference

Input - Optional

PRIM_OBJT

 

A reference to any RDMLX object.

Optionally used with the Execute() parameters to pass details to the command handler's uExecute method. 

TargetWindow

 

Input – Optional

 

Alpha – max length 256

 

 

Specifies the target window in which the switch operation should be performed. Allowable values are CURRENT (the current window), MAIN (the main window) or specific window name. The default value is MAIN.

KeepMaximize

Input – Optional

Boolean – default is False

This parameter MUST only be used in one specific scenario.

It can be used in VLF-WIN switching ONLY if ALL the folllowing are true:

a) The switch is initiated from one command handler and is a switch to another command in the same business object.

b) The switch is from an instance level command to a instance level command, or an object level command to an object level command.

c) The switch is within the same window.

A switch with KeepMaximize(True) used in ANY other context will result in unpredictable results and behaviour that may vary from release to release. DO NOT DO THIS.

If KeepMaximize(True) is used in the correct context, and if the first command handler had been expanded using avPaneMaximize, the switch to the new command handler will leave  the new command handler maximized. (The same behaviour as if the user had manually clicked on the tab of the second command handler).

 

Examples:

Refer to shipped example command handler DF_DET17.