Command PV SET DOCUMENT PROPERTY

4D View

PV SET DOCUMENT PROPERTY

version 6.8


PV SET DOCUMENT PROPERTY (area; option; value)

ParameterTypeDescription
areaLongint4D View area
optionLongintProperty number
valueLongintProperty value

Description

The PV SET DOCUMENT PROPERTY command sets the value of the property set by option for the 4D View document in area.

The PV Document properties constants are used to define the option parameter. These constants and their associated values are described below:

pv document modified

Allows setting or reading of the "modified" attribute of area. Associated values: pv value on or pv value off.

• when this constant is used in write mode ( PV SET DOCUMENT PROPERTY command), passing pv value on in the value parameter will cause a warning dialog box to be displayed when the area is closed indicating that it has been modified. If the value parameter contains pv value off, and if the document is not modified subsequently by the user or by programming, this dialog box does not appear.

• when this constant is used in read mode, using the PV Get document property command, the value returned is 1 if the document has been modified, and 0 otherwise.

pv column count

Allows setting or reading of the number of columns displayed in the area.

pv picture count

This constant is read-only ( PV Get document property command). It returns the number of pictures pasted into the area.

pv row count

Allows setting or reading of the number of rows displayed in the area.

pv no formula external call

Allows forbidding of calls to 4D variables, methods and commands in the formulas of the area. Associated values: pv value on or pv value off.

pv value on: calls to 4D variables, methods and commands are forbidden in the formulas (in this case, it is possible to use "PV Allows Input" theme commands to define which 4D objects can be called).

pv value off: calls to all 4D variables, methods and commands are allowed in the formulas (default value).

Examples

1. This generic method allows setting the number of columns and/or rows for a new 4D View area (during form load, for example).

      PV SET DOCUMENT PROPERTY (Area;pv column count;10)  `10 columns
      PV SET DOCUMENT PROPERTY (Area;pv row count;20)  `20 rows

2. This method, associated for example with a 4D View document close button, allows never displaying the alert dialog box indicating that the area has been modified:

   If (PV Get document property (Area;pv document modified)#0)
      PV SET DOCUMENT PROPERTY (Area;pv document modified;0)  `0 = unchanged, 1 = changed
   End if 
   

See Also

PV Get document property.

Constants

PV Document properties theme