Command PV SET RANGE PROPERTY

4D View

PV SET RANGE PROPERTY

version 2004 (Modified)


PV SET RANGE PROPERTY (area; left; top; right; bottom; property; value)

ParameterTypeDescription
areaLongint4D View area
leftLongintLeft cell column number
topLongintTop cell row number
rightLongintRight cell column number
bottomLongintBottom cell row number
propertyLongintProperty number
valueLongintProperty value

Description

The PV SET RANGE PROPERTY command sets the value of the property for the selected cell range defined using the left, top, right and bottom parameters. For more information on cell ranges, see the PV Selection, Introduction section.

To define property, you can use:

• the constants of the PV Cell properties theme. In this case, pass the height or width of the cell range in pixels in the value parameter.

• the constants of the PV Style properties theme. In this case, to define the value parameter, use the constants of the PV Style values, PV Style special values, PV Style format date time or PV Picture mapping mode theme.

The following list describes the different constants used in the property parameter and the associated values:

PV Cell properties theme

pv cell width

Allows setting of each cell width (and thus each column) contained in the defined range. Associated values: width expressed in pixels.

pv cell height

Allows setting of each cell height (and thus each row) contained in the defined range. Associated values: height expressed in pixels.

PV Style properties theme

pv style locked

Allows setting of locking in each cell of the range. Locked cell contents can no longer be modified, selected, etc. Associated values: constants of the PV Style values theme.

pv value on: cells locked.

pv value off: cells not locked.

pv style hidden

Allows setting of locking and hiding in each cell of the range. Locked and hidden cell contents are not displayed and can no longer be modified, selected, etc. Associated values: constants of the PV Style values theme.

pv value on: cells locked and hidden.

pv value off: cells not locked or hidden.

pv style spellcheck

Allows application of spellcheck for the cell range. Associated values: constants of the PV Style values theme.

pv value on: a spellcheck is applied to the cell range.

pv value off: no spellcheck is applied to the cell range.

pv style use picture height

Allows adapting of size of each cell in the range regarding the picture height associated with it. Associated values: constants of the PV Style values theme.

pv value on: the size of each cell in the range is adapted to the height of the picture it contains. If there is no picture associated with it, the cell is not resized.

pv value off: the size of the cells does not vary regarding the picture height associated with it.

pv style based on

Each cell in the range uses, as a model, the style sheet whose number is passed in the value parameter. Associated values: style sheet numbers or constants of the PV Style special values theme.

pv style format alpha

Each cell in the range uses the text display format whose number is passed in the value parameter. Associated values: display format numbers.

pv style format num

Each cell in the range uses the number display format whose number is passed in the value parameter. Associated values: display format numbers.

Note: Default display format numbers correspond to their position in the menu used for selecting formats in the cell Format dialog box.

pv style format bool

Each cell in the range uses the Boolean display format whose number is passed in the value parameter. Associated values: display format numbers.

pv style format date time

Each cell in the range uses the date and time display format whose number is passed in the value parameter. Associated values: constants of the PV Style format date time theme.

pv Short: 02/21/02

pv Abbreviated: thu 21 feb 2002

pv Long: thursday 21 february 2002

pv Short2: 02/21/2002

pv Month Day Year: 21 february, 2002

pv Abbr Month Day Year: 21 feb, 2002

pv Day Name: thursday

pv Day Number: 21

pv Month Name: february

pv Month Number: 2

pv Year Number: 2002

pv Long H MM AM PM: thursday 21 february 2002 at 12:30 PM

pv Abbreviated H MM AM PM: thu 21 feb 2002 at 12:30 PM

pv Short HH MM SS: 02/21/02 at 12:30:00

pv Month Day Year H MM AM PM: 21 february, 2002 at 12:30 PM

pv Short2 Hour Min Sec: 21/02/2002 and 12 hours 30 minutes 0 second

pv HH MM SS: 12:30:00

pv HH MM: 12:30

pv Hour Min Sec: 12 hours 30 minutes 0 second

pv Hour Min: 12 hours 30 minutes

pv HH MM AM PM: 12:30 PM

Note: Depending on your current System settings, the resulting display can be different.

pv style format picture

Allows definition of picture display format associated with each cell in the range. Associated values: constants of the PV Picture mapping mode theme.

pv mapping trunc non-centered

pv mapping truncated centered

pv mapping replicated

pv mapping scaled to fit prop

pv mapping scaled to fit

pv mapping scaled centered prop

pv style color back even

Allows setting of background color in each cell of the range if it is located on an even-numbered line. Associated values: color numbers (see the PV RGB to color and PV Index to color commands) or pv value none (PV Style Values theme) to set no color.

pv style color back odd

Allows setting of background color in each cell of the range if it is located on an odd-numbered line. Associated values: color numbers (see the PV RGB to color and PV Index to color commands) or pv value none (PV Style Values theme) to set no color.

pv style color text even

Allows setting of text color in each cell of the range if it is located on an even-numbered line. Associated values: color numbers (see the PV RGB to color and PV Index to color commands).

pv style color text odd

Allows setting of text color in each cell of the range if it is located on an odd-numbered line. Associated values: color numbers (see the PV RGB to color and PV Index to color commands).

pv style color zero even

Allows setting of text color in each cell of the range if it is located on an even-numbered line and its value is 0 (zero). Associated values: color numbers (see the PV RGB to color and PV Index to color commands).

pv style color zero odd

Allows setting of text color in each cell of the range if it is located on an odd-numbered line and its value is 0 (zero). Associated values: color numbers (see the PV RGB to color and PV Index to color commands).

pv style color minus odd

Allows setting of text color in each cell of the range if it is located on an even-numbered line and its value is negative. Associated values: color numbers (see the PV RGB to color and PV Index to color commands).

pv style color minus odd

Allows setting of text color in each cell of the range if it is located on an odd-numbered line and its value is negative. Associated values: color numbers (see the PV RGB to color and PV Index to color commands).

pv style text font

Allows setting of cell range font. Associated values: font numbers (see the PV Add font and PV GET FONT LIST commands).

pv style text size

Allows setting of cell range font size. Associated values: size in pixels.

pv style text face

Allows setting of cell range style sheet. Associated values: style sheet numbers or constants of the PV Style special values theme.

pv style text bold

Allows setting of Bold for the cell range text. Associated values: constants of the PV Style values theme.

pv value on: Bold applied in cells.

pv value off: Bold not applied in cells.

pv style text italic

Allows setting of Italic for the cell range text. Associated values: constants of the PV Style values theme.

pv value on: Italic applied in cells.

pv value off: Italic not applied in cells.

pv style text underline

Allows setting of Underline for the cell range text. Associated values: constants of the PV Style values theme.

pv value on: Underline applied in cells.

pv value off: Underline not applied in cells.

pv style text outline

Allows setting of Outline for the cell range text. Associated values: constants of the PV Style values theme.

pv value on: Outline applied in cells.

pv value off: Outline applied in cells.

pv style text shadow

Allows setting of Shadow for the cell range text. Associated values: constants of the PV Style values theme.

pv value on: Shadow applied in cells.

pv value off: Shadow not applied in cells.

pv style text condensed

Allows setting of Condensed for the cell range text. Associated values: constants of the PV Style values theme.

pv value on: Condensed applied in cells.

pv value off: Condensed not applied in cells.

pv style text extended

Allows setting of Extended for the cell range text. Associated values: constants of the PV Style values theme.

pv value on: Extended applied in cells.

pv value off: Extended not applied in cells.

pv style hor alignment

Allows setting of horizontal alignment of cell range content. Associated values: constants of the PV Style values theme.

pv value hor alignment default: applies horizontal alignment by default to the cell range.

pv value hor alignment left: applies left horizontal alignment to the cell range.

pv value hor alignment center: applies center horizontal alignment to the cell range.

pv value hor alignment right: applies right horizontal alignment to the cell range.

pv style vert alignment

Allows setting of vertical alignment of cell range content. Associated values: constants of the PV Style values theme.

pv value vert alignment top: applies top vertical alignment to the cell range.

pv value vert alignment center: applies center vertical alignment to the cell range.

pv value vert alignment bottom: applies bottom vertical alignment to the cell range.

pv style rotation

Allows setting of cell range content rotation. Associated values: constants of the PV Style values theme.

pv value rotation 0: no rotation applied to the cell range.

pv value rotation 90: applies 90° left rotation to the cell range.

pv value rotation 180: applies 180° rotation to the cell range.

pv value rotation 270: applies 270° left rotation to the cell range.

pv style format text forced

Allows "forcing" the cell range display in raw text, i.e. without the automatic display format applied by 4D View based on the cell contents (number, date, text, etc.). Associated values: constants of the PV Style values theme.

pv value on: cell range contents are displayed without automatic format.

pv value off (default): cell range contents are displayed with automatic format.

pv style automatic word wrap

Allows enabling the automatic word wrap function when the contents of a cell range exceed its width. Associated values: constants of the PV Style values theme.

pv value on: cell range contents automatically move to the next line if necessary.

pv value off: cell range contents run over into the adjacent cells if necessary.

Note: To define the property of a single cell, you can use the PV SET CELL PROPERTY command.

Example

Make all cells containing a formula referring to cell D20 appear in bold.

   ARRAY LONGINT($LeftArray;0)
   ARRAY LONGINT($TopArray;0)
   ARRAY LONGINT($RightArray;0)
   ARRAY LONGINT($BottomArray;0)
   C_INTEGER($Index)

   PV FIND ALL (Area;"$D$20";0;0)  `Formulas containing "$D$20"

      `Coordinates of selected cells
   PV GET SELECTED RANGES LIST (Area;$LeftArray;$TopArray;$RightArray;$BottomArray)

      `Make bold
   For ($Index;1;Size of Array($LeftArray))  `Sweep ranges
      PV SET RANGE PROPERTY (Area;$LeftArray{$Index};$TopArray{$Index};$RightArray{$Index};$BottomArray{$Index};pv style text bold ;pv value on)
   End for

See Also

PV Get cell property, PV Get range property, PV SET CELL PROPERTY.

Constants

PV Style properties, PV Cell properties, PV Style values, PV Style special values, PV Style format date time and PV Picture mapping mode themes.