ShowHeadFoot

Description

Displays the panels for editing the header and footer in a RichTextEdit control or hides the panels and returns to editing the main text.

Applies to

DataWindow type

Method applies to

PowerBuilder

DataWindow control with RichTextEdit presentation style

Syntax

PowerBuilder

integer rtename.ShowHeadFoot ( boolean editheadfoot, {headerfooter} )

Argument

Description

rtename

A reference to the DataWindow control for which you want to edit header and footer information. The DataWindow must have a RichTextEdit presentation style.

editheadfoot

A boolean value specifying the editing panel to display. Values are:

  • True – Display the header and footer editing panels.

  • False – Display the detail editing panel for the document body.

headerfooter (optional)

A boolean value specifying whether the insertion point (caret) for editing the header/footer panel is in the header or the footer section. Values are:

  • True Caret is in the header section.

  • False Caret is in the footer section.

Returns

Returns 1 if it succeeds and –1 if an error occurs.

Usage

ShowHeadFoot takes effect when the control is in preview mode or when it is in edit mode for the main text. If the control is in preview mode, calling ShowHeadFoot returns to edit mode. The value of editheadfoot determines whether the main text or the header and footer panels display.

The headerfooter argument is ignored if the editheadfoot argument is false. The headerfooter argument defaults to “true” if a value is not provided. The header and footer can include input fields for page numbers and dates.

NotePowerBuilder RichTextEdit control You can use the same syntax with any RichTextEdit control. See ShowHeadFoot in the PowerScript Reference.

See also