Variables can be assigned to everything
Variables can be defined in several places throughout the Profile/Checks/Fixups editor. Variables may be assigned to virtually every control including the severity for a check:
- Text input fields
- Pop Up fields
- On/Off switch in order to enable/disable Checks or Fixups in a Profile
Assign a variable
When you click on a variable icon in the pdfToolbox Profiles/Checks/Fixups editor, you will see a list of all variables that are present in the system. Variables that are used in the current context (e.g. the current Profile) appear at the top. You may pick any of the existing variables, create a new one or edit one that is already assigned.
Managing and deleting a variable
Deleting a variable is currently only possible in the Library Manager and only if the variable is not used. Whether or not a variable is used can also be seen there.
Variable Editor: Creating a new variable
For Checkboxes and Pop ups you can use the info button to pick one of the possible default values
Constraints can be defined by using the "Limit input values to specific values" checkbox in the variable editor. In this context the expected value type of the variable is important which is indicated above of input field for the default value.
You may in addition specify:
- whether a Browse button shows up when executed in pdfToolbox Desktop that allows a user to pick a file from the system (e.g. to load an ICC profile)
- whether the entries in Values are used as list, in which case a Pop up would show up in the dialogue of pdfToolbox Desktop or as a range. In the latter case invalid values that are out of range will be indicated by a red cross.
Constraints - Range specifics
When you are using the Range option, two values will define a range and a single value defines a single allowed value. In this example 100-300 and 500 are permitted values (which usually does not make sense).
Constraints for Pop up fields
You may again use the info button in order to pick possible values for the Pop up. In this example this is done for a severity, but it works in the same way for other Pop up fields.
Profile Script Scope
Variables in Processplans
It is possible to define a variable as a step in a Process Plan. This will work similar to a Variable on Profile level in does only makes sense and work for Script variables.
The "Ask at runtime" in pdfToolbox Desktop
In pdfToolbox Desktop a dialogue shows up, when a Profile/Check/Fixup is executed that has editable variables, i.e. variables that are not calculated by means of Scripts. If you want to see the dialogue for a Profile/Check/Fixup that only has calculated variables you will have to add one additional variable that is not calculated.
Script variables are hidden as long as no evaluation errors had occurred. If an evaluation error has occurred the OK button is disabled. Details can be displayed by clicking the “Inspect variable” checkbox. It allows you to analyze the structure of all variables in the given context.