Options Directive (DPL Code)
DPL allows you to control the settings of compile-time options from a DPL program file. These options can be set within the Run Settings dialog or in DPL code. This feature can be very useful if forgetting to set an option results in long run times or unexpected results.
Like the #if, #else, and #include directives, the #options option list directive must begin in the first column of a line. In general, this directive should be used only once and near the beginning of a program file.
The option list consists of a sequence of letters separated by commas, indicating the options to be set. There are five compile-time options that can be set in an options directive:
- e - (for expression optimization)
- s - (for Fast Sequence Evaluation)
- l - (for lottery optimization)
- x - (Excel lookup function convention)
- i - (ignore case when comparing strings)
#options -e, +l
This will turn expression optimization off and turn lottery optimization on. In this example, series optimization would be controlled by the settings in Home | Run.
#options +x, +i
DPL will use Excel conventions when evaluating lookups and string comparisons.
#options -x, +i
DPL will use Lotus 1-2-3 conventions when evaluating lookups and string comparisons.
Versions: DPL Professional, DPL Enterprise, DPL Portfolio