TransferModeless

Mon 01 January 2018

Syntax

TransferModeless( MENUNAME.menuname, BARNAME.barname, ITEMNAME.menu_itemname, PAGE.component_item_name, action [, keylist] [, AutoSearch])

In which keylist is a list of field references in the form:

[recordname.]field1 [, [recordname.]field2].
. .

Or in which keylist is a list of field references in the form:

&RecordObject1 [, &RecordObject2].  .  .

Description

Use the TransferModeless function to open a new page in a modeless window on top of the parent window. Only one modeless window can be opened per browser session. Similar to the new_instance parameter of the Transfer function, TransferModeless instantiates a separate instance of the component processor so that the parent window and secondary window are completely independent PeopleCode contexts.

Note: TransferModeless is currently not supported for transfers from or to fluid components. In addition, TransferModeless function cannot be used with an Internet script or an Application Engine program.

TransferModeless is more powerful than the simpler TransferPage, which permits a transfer only within the current component in the current instance of PeopleTools. However, any variables declared as component do not remain defined after using the TransferModeless function, whether you’re transferring within the same component or not.

You can use TransferModeless from a secondary page (either with or without using a pop-up menu) only if you’re transferring to a separate instance of a component. You cannot use TransferModeless from a secondary page if you’re not transferring to a separate instance of a component.

If you provide a valid search key for the new page in the optional keylist , the new page opens directly, using the values provided from keylist as search key values. A valid key means that enough information is provided to uniquely identify a row: not all of the key values need to be provided. If no key is provided, or if the key is invalid, or if not enough information is provided to identify a unique row, the search dialog box displays, enabling the end user to search for a row.

Note: If Force Search Processing is specified in Application Designer for the component, the search dialog box always displays, whether the keylist is provided or not.

If barname + itemname + component_item_name is an invalid combination, an error message displays explaining that there were invalid transfer parameters.

In the component_item_name parameter, make sure to pass the component item name for the page, not the page name.

Image: Determining the component item name

The component item name is specified in the component definition, in the Item Name column on the row corresponding to the specific page, as shown here. In this example, the PERSONAL_DATA page name appears twice: once with an item name of PERSONAL_DATA_1, and once with the item name of PERSONAL_DATA_2.

Determining the component item name

Parameters

Field or Control

Definition

Menuname

The name of the menu where the page is located prefixed with the reserved word MENUNAME .

Barname

The name of the menu bar where the page is located, prefixed with the reserved word BARNAME .

menu_itemname

The name of the menu item where the page is located, prefixed with the reserved word ITEMNAME .

component_item_name

The component item name of the page to be displayed on top of the component when it displays. The component item name is specified in the component definition. This parameter must be prefixed with the keyword PAGE .

Action

Uses a single-character code as in %Action. Valid actions are "A" ( add), "U" (update), "L" (update/display all), "C" (correction), and "E" (data entry).

Keylist

An optional list of field specifications used to select a unique row at level zero in the page you are transferring to, by matching keys in the page you are transferring from. It can also be an already instantiated record object.

If a record object is specified, any field of that record object that is also a field of the search record for the destination component is added to keylist. The keys in the fieldlist must uniquely identify a row in the "to" page search record. If a unique row is not identified, or if Force Search Processing is selected for the component, the search dialog box appears.

If the keylist parameter is not supplied then the destination component's search key must be found as part of the source components level 0 record buffer.

AutoSearch

Specify whether an automatic search on the target search page is executed after the transfer. This means the search results are already shown without the end user having to click the Search button. This parameter takes a Boolean value: True, do an automatic search. The default value is False (that is, the user has to click the Search button).

Returns

None.