4D v13

PV SET AREA PROPERTY

Home

 
4D View v13
PV SET AREA PROPERTY

PV SET AREA PROPERTY 


 

PV SET AREA PROPERTY ( area ; property ; value ) 
Parameter Type   Description
area  Longint in 4D View area
property  Longint in Property number
value  Longint in Property value

The PV SET AREA PROPERTY command sets the value of the property for the specified 4D View area.

Only the properties preferences of areas displayed on screen—present in a form, associated with a field or not — are saved:

  • They are loaded every time a form containing the area is opened,
  • They are saved every time the area is closed.
  • They can be located on the client or the server.

If area is set to 0, the PV SET AREA PROPERTY command will be applied to all new 4D View areas. In this case, it is better to call it using the On Startup Database Method, executed when the database is opened.

The PV Area properties constants are used to define the property parameter. To define the value parameter, use the appropriate constant themes or pass a specific value. The following table details each PV Area properties constant and the corresponding value parameters:

Constant Type Value Comment
pv allow undo redo Longint 39 Allows (or not) the use of the undo function. Associated values:
  • pv value on: The undo functionality is on (default value).
  • pv value off: The undo functionality is off (the Undo command of the Edit menu is inactive).
pv arrow keys Longint 9 Allows defining the use of the arrow keys to validate data entry (validation and selection of the next cell). The validation is carried out only when the cursor is placed at the beginning or end of the cell content. Associated values: constants of the PV Arrow keys theme.
  • pv arrow keys allowed: Allows the use of all arrow keys.
  • pv top and bottom arrow keys: Allows only the use of top and bottom arrow keys.
  • pv right and left arrow keys: Allows only the use of right and left arrow keys.
  • pv arrow keys not allowed: Does not allow the use of arrow keys for data validation.
pv carriage return Longint 8 Allows the creation of new lines in a cell (multi-line cells). Associated values: constants of the PV Carriage return theme.
  • pv cr not allowed: Multi-line data entry is not allowed in the area.
  • pv cr allowed: Pressing the Carriage Return key will create a new line in the cell.
  • pv cr allowed with ctrl: Pressing Ctrl+Carriage Return (Command+Carriage Return on Mac OS) will create a new line in the cell.
  • pv cr allowed with shift: Pressing Shift+Carriage Return will create a new line in the cell.
pv column headers height Longint 21 Allows setting or reading of the column headers' height in the area. Associated values: headers' height (in pixels).
pv copy hidden Longint 19 Allows the setting of whether the hidden elements included in the area must be taken into account when cells are copied. Associated values:
  • pv value on: Hidden elements (if any) are taken into account when cells are copied.
  • pv value off: Hidden elements (if any) are not taken into account when cells are copied.
pv current cell highlight Longint 3 Allows setting of the highlighting for the current cell in the area. Associated values:
  • pv value on: The current cell is highlighted in the area, it is therefore visible on screen.
  • pv value off: The current cell is not highlighted in the area, it is therefore invisible on screen.
    By default, the active cell is highlighted.
pv drag allowed Longint 13 Allows setting of the type of selection that can be dragged. Associated values: constants of the PV Drag drop allowed theme.
  • pv DD not allowed: No selection can be dragged in the area—even if drag and drop is allowed.
  • pv DD single cell: Single cell selections can be dragged.
  • pv DD adjacent cells: Multiple adjacent cells or a single-cell selection can be dragged.
  • pv DD multiple cells: Multiple cells (adjacent or not) or a single-cell selection can be dragged.
  • pv DD single row: Single row selections can be dragged.
  • pv DD adjacent rows: Multiple adjacent rows or single row selections can be dragged.
  • pv DD multiple rows: Multiple rows (adjacent or not) or a single-row selection can be dragged.
  • pv DD single column: Single column selections can be dragged.
  • pv DD adjacent columns: Multiple adjacent columns or a single-column selection can be dragged.
  • pv DD multiple columns: Multiple columns (adjacent or not) or a single-column selection can be dragged.

Note: You can add several constants for the same area. For example, PV SET AREA PROPERTY(area; pv drag allowed; pv DD multiple cells + pv DD single column + pv DD adjacent rows) allows dragging of a selection containing either multiple cells or a single column or adjacent rows.

pv drag trigger Longint 12 Allows the definition of the drag trigger in the area. There is no specific trigger for the drop. Associated values: constants of the PV Triggers theme.
  • pv trigger none: Dragging is not allowed in the area.
  • pv trigger on click: The selection can be dragged using a mouse click.
  • pv trigger on double click: The selection can be dragged using a mouse double-click.
  • pv trigger on alt click: The selection can be dragged using an Alt+click combination.
  • pv trigger on alt double click: The selection can be dragged using an Alt+double-click combination.
  • pv trigger on ctrl click: The selection can be dragged using a Ctrl+click combination (Command+click on Mac OS).
  • pv trigger on ctrl double click: The selection can be dragged using a Ctrl+double-click combination (Command+double-click on Mac OS).
  • pv trigger on shift click: The selection can be dragged using a Shift+click combination.
  • pv trigger on shift double clic: The selection can be dragged using a Shift+double-click combination.

Note: When the same trigger is defined for both drag and selection, the drag trigger has priority.

pv drop allowed Longint 33 Allows setting of the type of selection which can be dropped in the area. Associated values: constants of the PV Drag drop allowed theme.
  • pv DD not allowed: No selection can be dropped in the area—even if drag and drop is allowed.
  • pv DD single cell: Single cell selections can be dropped.
  • pv DD adjacent cells: Multiple adjacent cells or a single-cell selection can be dropped.
  • pv DD multiple cells: Multiple cells (adjacent or not) or a single-cell selection can be dropped.
  • pv DD single row: Single row selections can be dropped.
  • pv DD adjacent rows: Multiple adjacent rows or single row selections can be dropped.
  • pv DD multiple rows: Multiple rows (adjacent or not) or a single-row selection can be dropped.
  • pv DD single column: Single column selections can be dropped.
  • pv DD adjacent columns: Multiple adjacent columns or a single-column selection can be dropped.
  • pv DD multiple columns: Multiple columns (adjacent or not) or a single-column selection can be dropped.
  • pv DD 4D objects: 4D objects can be dropped. All types of 4D fields (except for BLOBs and sub-tables) and variables (except for BLOBs) can be dropped.

Note: You can add several constants for the same area. For example, PV SET AREA PROPERTY(area; pv drop allowed;pv DD multiple cells + pv DD single column + pv DD adjacent rows) allows the dropping of a selection containing either multiple cells or a single column or adjacent rows.

pv drop mode Longint 14 Allows setting of how a dragged selection can be dropped in the area. Note that this property only defines the way in which the dragged values will be pasted into the drop area; the copy of the dragged values (if any) must be managed separately. Associated values: constants of the PV Drop mode theme.
  • pv drop insert or replace: Dropped values can be inserted or replace existing values in the area.
  • pv drop insert only: Dropped values can only be inserted in the area.
  • pv drop replace only: Dropped values can only replace existing values in the area.
pv field tag Longint 17 Allows setting of the field separator. This property is useful for data import/export only. Associated values: character ASCII code.
Example : "E1Field1", "E1Field2", "E1Field3"; "E2Field4", "E2Field5";
The comma is the field separator.
pv field wrapper Longint 18 Allows setting of the field wrapper. This property is useful for data import/export only. Associated values: character ASCII code.
Example : "E1Field1", "E1Field2", "E1Field3"; "E2Field4", "E2Field5";
The quotes are the field wrappers.
pv headers sort Longint 20 Lets you allow or forbid the standard sorting of data when a column header is clicked (dynamic or static data). Associated values: the following constants of the PV Header sort theme.
  • pv sort not allowed (default value): 4D View does not carry out a standard sort when the user clicks on a column header (the sort can nevertheless be managed by the developer in a customized manner).
  • pv sort allowed: 4D View carries out a standard sort when the user clicks on a column header. In this case, a symbol appears in the header in order to indicate the sort order. Successive clicks cause alternating ascending and descending sorts.
Sorting a dynamic column produces a synchronized sort of the other columns so that the records always remain in their initial state. A sort on a static column only sorts that column.
pv hor pane count Longint 11 Allows the reading of the number of horizontal panes in the area. This constant can only be read using the PV Get area property command. Returned values: pane count.
pv input enter key mode Longint 15 Allows setting of the action of the Enter key (numeric keypad) when pressed during data entry. Associated values: constants of the PV Input enter key mode theme.
  • pv enter key standard: The Enter key validates the current cell then switches between selection/data entry in the same cell (the current cell does not change).
  • pv enter key as tab: The Enter key validates the current cell then switches between selection/data entry in the next cell to the right. The Shift+Enter key combination switches between selection/data entry in the next cell to the left.
  • pv enter key as return: The Enter key validates the current cell then switches between selection/data entry in the next cell below. The Shift+Enter key combination switches between selection/data entry in the next cell above.

Note: Unlike the Enter key, the Tab and Carriage Return keys only select cells.

pv input trigger Longint 6

Allows setting of the input trigger(s) in the area. Data entry can only be carried out in the current active cell. Associated values: the following constants of the PV Triggers theme:

  • pv trigger none: Data entry is deactivated (no event will trigger input), even if a key is allowed in the data input mode (see constant pv input enter key mode). Data entry is, however, still possible using the Formula Editor toolbar, and the selection may be changed as well.
  • pv trigger input key: Data entry is triggered by any keystroke. In this case, browsing between cells is only possible using the keyboard (Tab and Shift+Tab to move horizontally, Carriage return and Shift+Carriage return to move vertically, or the arrow keys).
  • pv trigger input on enter: Data entry is triggered by the Enter key (numerical keypad).
  • pv trigger input on gain sel: Data entry is triggered in the cell which has the focus. In this mode, as soon as a cell is selected, it takes the focus and the cursor becomes an input cursor.
  • pv trigger on click: Data entry is triggered by a click in a cell. Unlike the pv trigger input on gain sel constant, no input cursor is displayed.
  • pv trigger on double click: Data entry is triggered by a double-click in a cell. A single click does not permit input.
  • pv trigger on alt click: Data entry is triggered by a Alt+click combination in a cell.
  • pv trigger on alt double click: Data entry is triggered by a Alt+double-click combination in a cell.
  • pv trigger on ctrl click: Data entry is triggered by a Ctrl+click (Command+click on Mac OS) combination in a cell.
  • pv trigger on ctrl double click: Data entry is triggered by a Ctrl+double-click (Command+double-click on Mac OS) combination in a cell.
  • pv trigger on shift click: Data entry is triggered by a Shift+click combination in a cell.
  • pv trigger on shift double clic: Data entry is triggered by a Shift+double-click combination in a cell.

Notes:

  • You can add several constants for the same trigger. For example, PV SET AREA PROPERTY(area; pv input trigger;pv trigger on click + pv trigger on alt click) allows the use of a click OR an Alt+click for data entry.
  • When the same trigger is defined for both input and selection, the input trigger has priority.
pv record tag Longint 16 Allows setting of the record separator. This property is useful for data import/export only. Associated values: character ASCII code.
Example : "E1Field1", "E1Field2", "E1Field3"; "E2Field4", "E2Field5";
The semicolon is the record separator (2 records: E1 and E2).
pv resizable columns Longint 4 To allow (or not) column resizing. Associated values:
  • pv value on: Columns in the area are resizable.
  • pv value off: Columns in the area are not resizable.
pv resizable rows Longint 5 To allow (or not) row resizing. Associated values:
  • pv value on: Rows in the area are resizable.
  • pv value off: Rows in the area are not resizable.
pv row headers width Longint 22 Allows setting or reading of the row headers' width in the area. Associated values: headers' width (in pixels).
pv saving dialog Longint 37 Allows displaying (or not) of the Save document confirmation alert when a 4D View document which has been modified is closed. This alert is displayed when a 4D View included area—not associated with a database field— is exited (the form is validated or canceled). This property is not valid for external 4D View windows. Associated values:
  • pv value on: The confirmation alert is displayed (default value).
  • pv value off: The confirmation alert is not displayed.
pv select highlight Longint 1 Allows setting of the highlighting for cell selections in the area. Associated values:
  • pv value on: Selections are highlighted in the area.
  • pv value off: Selections are not highlighted, they are then invisible on screen.
pv select mode Longint 0 Allows setting of the selection actions allowed for the area. Associated values: constants of the PV Select mode theme.
  • pv select not allowed: No selection is possible in the area (all cells are deselected). Data entry is also not allowed (the formula editor is locked). Data can only be viewed.
  • pv select single row: Only one row at a time can be selected in the area.
  • pv select adjacent rows: Only adjacent rows can be selected in the area.
  • pv select multiple rows: Multiple rows, adjacent or not, can be selected in the area.
  • pv select single column: Only one column at a time can be selected in the area.
  • pv select adjacent columns: Only adjacent columns can be selected in the area.
  • pv select multiple columns: Multiple columns, adjacent or not, can be selected in the area.
  • pv select single cell: Only one cell at a time can be selected in the area.
  • pv select adjacent cells: Only adjacent cells can be selected in the area.
  • pv select multiple cells: Multiple cells, adjacent or not, can be selected in the area.
Note: Data entry remains possible in the selection (except during the use of the pv select not allowed constant). If you want to forbid all data entry in the area, you must, furthermore, execute the statement PV SET AREA PROPERTY(area;pv input trigger;pv trigger none).
pv select null Longint 2 To allow (or not) areas without a current selection. Associated values:
  • pv value on: A selection is not mandatory in the area. For example, if the column or row containing the current active cell is deleted, there is no longer any selection in the area.
  • pv value off: A selection is mandatory in the area.pv value on or pv value off.
pv select trigger Longint 7

Allows setting of the selection trigger(s) in the area. Associated values: the following constants of the PV Triggers theme:

  • pv trigger none: Selection is not allowed in the area. It is still possible to enter data in the selection that was current before the command is executed—Tab and Carriage return keys move the active cell within the selection.
  • pv trigger select on arrow: Selection is defined (active cell only) using the arrow keys. Extending or reducing a selection is not possible.
  • pv trigger select on tab: Selection is defined (active cell only) using the Tab key or the Shift+Tab key combination. Extending or reducing a selection is not possible.
  • pv trigger select on return: Selection is defined (active cell only) using the Carriage Return key. Extending or reducing a selection is not possible.
  • pv trigger on click: Selection is defined via mouse clicks.
  • pv trigger on double click: Selection is defined (active cell only) via mouse double-clicks. Extending or reducing a selection is not possible.
  • pv trigger on alt click: Selection is defined using the Alt+click combination.
  • pv trigger on alt double click: Selection is defined using the Alt+double-click combination.
  • pv trigger on ctrl click: Selection is defined using the Ctrl+click combination (Command+click on Mac OS).
  • pv trigger on ctrl double click: Selection is defined using the Ctrl+double-click combination (Command+double-click on Mac OS).
  • pv trigger on shift click: Selection is defined using the Shift+click combination.
  • pv trigger on shift double clic: Selection is defined using the Shift+double-click combination.

Notes:

  • You can add several constants for the same trigger. For example, PV SET AREA PROPERTY(area; pv select trigger;pv trigger on click + pv trigger on alt click) allows the use of a click OR an Alt+click for the selection.
  • When the same trigger is defined for both input and selection, the input trigger has priority.
  • When the same trigger is defined for both drag and selection, the drag trigger has priority.
pv show borders toolbar Longint 29 Allows showing or hiding of the 4D View Borders toolbar in the area. Associated values:
  • pv value on: The Borders toolbar is shown.
  • pv value off: The Borders toolbar is hidden.
pv show column headers Longint 23 Allows showing or hiding of the area column headers. Associated values:
  • pv value on: Column headers are shown.
  • pv value off: Column headers are hidden.
pv show formula toolbar Longint 30 Allows showing or hiding of the 4D View Formula toolbar in the area. Associated values:
  • pv value on: The Formula toolbar is shown.
  • pv value off: The Formula toolbar is hidden.
pv show hor grid Longint 31 Allows showing or hiding of the 4D View horizontal grid within the area. Associated values:
  • pv value on: The horizontal grid is shown.
  • pv value off: The horizontal grid is hidden.
pv show hor scrollbar Longint 34 Allows showing or hiding of the 4D View horizontal scrollbar within the area. Associated values:
  • pv value on: The horizontal scrollbar is shown.
  • pv value off: The horizontal scrollbar is hidden.
pv show menu bar Longint 25 Allows showing or hiding of the 4D View Menu bar in the area. Associated values:
  • pv value on: The Menu bar is shown.
  • pv value off: The Menu bar is hidden.
pv show numbers toolbar Longint 27 Allows showing or hiding of the 4D View Numbers toolbar in the area. Associated values:
  • pv value on: The Numbers toolbar is shown.
  • pv value off: The Numbers toolbar is hidden.
pv show row headers Longint 24 Allows showing or hiding of the area row headers. Associated values:
  • pv value on: Row headers are shown.
  • pv value off: Row headers are hidden.
pv show selection Longint 40 Allows setting or getting the selection display mode in a 4D View area not having the focus. Associated values:
  • pv value on : the selection of the area always remains visible (highlighted) whether or not the 4D View area has the focus.
  • pv value off : when the 4D View area loses the focus, the selection is no longer visible.
pv show standard toolbar Longint 26 Allows showing or hiding of the 4D View Standard toolbar in the area. Associated values:
  • pv value on: The Standard toolbar is shown.
  • pv value off: The Standard toolbar is hidden.
pv show style toolbar Longint 28 Allows showing or hiding of the 4D View Style toolbar in the area. Associated values:
  • pv value on: The Style toolbar is shown.
  • pv value off: The Style toolbar is hidden.
pv show vert grid Longint 32 Allows showing or hiding of the 4D View vertical grid within the area. Associated values:
  • pv value on: The vertical grid is shown.
  • pv value off: The vertical grid is hidden.
pv show vert scrollbar Longint 35 Allows showing or hiding of the 4D View vertical scrollbar within the area. Associated values:
  • pv value on: The vertical scrollbar is shown.
  • pv value off: The vertical scrollbar is hidden.
pv vert pane count Longint 10 Allows the reading of the number of vertical panes in the area. This constant can only be read using the PV Get area property command. Returned values: pane count.

Reminder: A pane is the area located between two splitters (a splitter can be horizontal or vertical).

pv zoom factor Longint 36 Allows setting or reading of the zoom value (in percent) for the area. Associated values: zoom rate included between 25 and 1000.

Example  

To freeze column size in a 4D View area or to authorize resizing if this function is frozen, we will write the following method which will carry out the "switch":

 C_INTEGER($Value`Property value
 
  `Current value (0: froze, 1 = authorized)
 $Value:=PV Get area property(Area;pv resizable columns)
  `Switching command : 0 <-> 1
 PV SET AREA PROPERTY(Area;pv resizable columns;Num($Value=0))

 
PROPERTIES 

Product: 4D
Theme: PV Area
Number: 15996

 
INDEX

Alphabetical list of commands

 
HISTORY 

Modified: 4D View 2004

 
SEE ALSO 

PV Get area property