@SetTargetFrame (Formula Language)

Allows you to specify a target frame when opening a view, page, or frameset, or when composing or editing a document.

Note: This @function is new with Release 5.

Syntax

@SetTargetFrame( targetframe )

Parameters

targetframe

Text. The name of the frame that a view, page, frameset, or document should open into.

Usage

Use @SetTargetFrame before opening or refreshing the view, page, or frameset, or before composing or editing a document. The following @commands use the frame specified in the @SetTargetFrame:

If you specify the newinstance parameter for @Command([OpenView]), the @SetTargetFrame function is ignored.

If you do not specify a viewName for@Command([OpenView]), then the last view is the one that opens in the specified targetframe of @SetTargetFrame.

If you specify a targetFrame parameter for @Command([RefreshFrame]), the @SetTargetFrame function is ignored.

@SetTargetFrame can be used in action and hotspot formulas.

Examples

Consider 2 framesets -- one that contains "Frame A" and "Frame B" and another frameset nested within "Frame B" that contains "Frame C" and "Frame D."

This example opens the view "My View" in "Frame A" of the first frameset.

@SetTargetFrame("Frame A");
@Command([OpenView]; "My View");
 

This example is code in a button on "Frame C" of the nested frameset. It opens the form "My form" in "Frame D" of the same frameset:

@SetTargetFrame("Frame D");
@Command([Compose]; "My form");