Bandname.property

Description

Settings for the color, size, and pointer of a band in the DataWindow object. The gradient settings do not work in reports.

Applies to

DataWindows

Syntax

PowerBuilder dot notation:

dw_control.Object.DataWindow.bandname.property

Describe and Modify argument:

"DataWindow.bandname{.#}.property { = value }"

Parameter

Description

bandname

The identifier of a band in the DataWindow object.

Values are:

  • Detail

  • Footer

  • Summary

  • Header

  • Trailer

  • Tree.Level

Setting the header.#, trailer.#, and tree.level.# bands

You cannot use dot notation to set the header.#, trailer.#, and tree.level.# bands.

#

The number of the group or TreeView level you want when bandname is Header, Trailer, or Tree.Level. The group must exist.

property

A property that applies to the band, as listed in the table below.

value

Values for the properties are shown in the following table.


 

Property for Bandname

Value

Brushmode

(exp) An integer indicating the type of "brush" to use for the gradient.

Values are:

0 -- Solid

1 -- Horizontal

2 -- Vertical

3 -- Angle

4 -- ScaledAngle

5 -- Radial

Painter: Background tab, Gradient group (not available for RichText, Graph, or OLE DataWindow objects).

Color

(exp) A long specifying the color (the red, green, and blue values) to be used as the band's background color. Value can be a quoted DataWindow expression.

Painter: General tab.

Height

An integer specifying the height of the detail area in the unit of measure specified for the DataWindow.

Painter: General tab.

For another way of setting the height of the detail band, see the SetDetailHeight method.

Height.AutoSize

Allows the band to grow to display a row, picture, or nested report without cutting off any of its content. In the detail band, selecting this property sets the minimum height for all rows to the size specified by the Height property for the band.

Values are:

No -- Fixes the band height to the size set for the Height property of the band.

Yes -- Adjusts the band height to accommodate the full content of a row or the controls in the band. However, the band height cannot be reduced below the value set for the Height property of the band.

This property can be especially useful to set on the detail band when it contains rows with a text column that you want to display without cutting off any of the text. The height of the detail band must not grow larger than a page, except when it contains nested DataWindows with the Report.Height.AutoSize property set to Yes.

You can set this property on individual columns and controls as well as on the band itself. For more information, see the Height.AutoSize property for DataWindow objects.

There are some limitations on the use of this property:

  • The Height.Autosize property is not supported on DataWindows with Graph, Label, OLE, or Rich Text presentation styles.

  • Nested report overflow to the next page is supported in detail bands only.

  • Bands cannot be autosized if autosizing would preclude the display of at least one detail band row per page.

Painter: General tab when the band is selected.

Pointer

(exp) A string specifying a value of the Pointer enumerated datatype or the name of a cursor file (.CUR) to be used for the pointer. See the section called “SetPointer” in PowerScript Reference for a list of Pointer values. Pointername can be a quoted DataWindow expression.

Painter: Pointer tab.

Suppress

A boolean that lets you suppress group headers after page breaks. You can set this property on group header bands only. When a group listing straddles a page break, all group headers for which you set this property will be suppressed. The suppressed headers do not display at the top of the page. However, if the page break coincides with the start of a new group, only headers above the current group header can be suppressed.

Values are:

No -- Does not suppress group headers.

Yes -- Suppresses group headers.

Painter: General tab when a group header band is selected.

Transparency

(exp) An integer in the range 0 to 100, where 0 means that the background is opaque and 100 that it is completely transparent.

Painter: Background tab.

Gradient.Angle

(exp) An integer indicating the angle in degrees (values are 0 to 360) used to offset the color and transparency gradient. This property is used only when the DataWindow band gradient.mode takes values of 3 or 4.

Painter: Background tab, Gradient group.

Gradient.Color

(exp) A long specifying the color (the red, green, and blue values) to be used as the band object's secondary background color. The gradient defines transitions between the primary and secondary background colors. Value can be a quoted DataWindow expression.

Painter: Background tab.

Gradient.Focus

(exp) An integer in the range 0 to 100, specifying the distance (as a percentage) from the center where the background color is at its maximum. (For example, if the radial gradient is used and the value is set to 0, the color will be at the center of the background; if the value is set to 100, the color will be at the edges of the background.)

Painter: Background tab, Gradient group

Gradient.Scale

(exp) An integer in the range 0 to 100 specifying the rate of transition to the gradient color (as a percentage).

Painter: Background tab, Gradient group

Gradient.Spread

(exp) An integer in the range 0 to 100 indicating the contribution of the second color to the blend (as a percentage).

Painter: Background tab, Gradient group

Gradient.Repetition.Mode

(exp) Specifies the mode for determining the number of gradient transitions for band background color and transparency.

Permitted values and their meanings are:

  • 0

    Gradient.repetition.count determines the number of gradient transitions

  • 1

    Gradient.repetition.length determines the number of gradient transitions

Painter: Background tab, Gradient group.

Gradient.Repetition.Count

(exp) An integer specifying the number of gradient transitions for background color and transparency. A value of 0 indicates 1 transition. A value of 3 indicates 4 transitions. This property is used only when the gradient.repetition.mode property for the DataWindow band takes the value of 0 (by count).

Painter: Background tab, Gradient group.

Gradient.Repetition.Length

(exp) A long specifying the number of gradient transitions. This property is used only when the gradient.repetition.mode property for the DataWindow band takes the value of 1 (by length). The units for the length that you assign for the band's gradient transitions are set by the DataWindow object's Units property.

Painter: Background tab, Gradient group.

Gradient.Transparency

(exp) An integer in the range 0 to 100, where 0 means that the band's secondary (gradient) background is opaque and 100 that it is completely transparent. The gradient defines transitions between the primary and secondary transparency settings.

Painter: Background tab, Gradient group.


Usage

In the painter

Select the band by clicking the gray divider for the band. Set the value in the Properties view.

Examples

string ls_data
ls_data = dw1.Object.DataWindow.Detail.Height
dw1.Object.DataWindow.Detail.Pointer = "hand.cur"
 
ls_data = dw1.Describe("DataWindow.Detail.Height")
ls_data = &
   dw1.Describe("DataWindow.Detail.Height.AutoSize")
dw1.Modify("DataWindow.Detail.Pointer='hand.cur'")
dw1.Modify("DataWindow.Detail.Pointer='~"Cross!~" ~t 
if(emp_status=~"a~", ~"HourGlass!~", ~"Cross!~")'")
dw1.Modify("DataWindow.Footer.Height=250")
ll_color = RGB(200, 200, 500)
dw1.Modify("DataWindow.Header.2.Color=" &
   + String(ll_color))
dw1.Modify("DataWindow.Trailer.2.Height=500")
dw1.Modify( &
  "DataWindow.Summary.Pointer='c:\pb\total.cur'")