Using variables in PerfectScript

A variable acts as a place holder that represents a value, which can be text, numbers, or measurements, that you can use repeatedly in a macro. You can change or manipulate this value in the macro. WordPerfect allows you to use the commands, such as Constant, Declare, Global, Indirect, Local, and Persist, to create variables with different functions and actions.

Variables are typically preceded by the letter “v”.


To assign a variable in PerfectScript

WordPerfect Office btnbacktotopproc Using variables in PerfectScript
 
Type the Assign macro command where you want to define the variable.
For example, type Assign (vName; “Lori”) to assign the text “Lori” to the variable “vName”.

WordPerfect Office tip Using variables in PerfectScript

 
You can type a colon followed by the equals sign (:=) as a shortcut to assigning a variable. For example, you could type vName:=“Lori” for the above example.

Using variables in PerfectScript