Enumerations, Sets and Arrays
DBF Script supports enumerations. You can write in a script:
Form1.BorderStyle := bsDialog;
|
Sets are not supported. However, you can use set constants in the following way:
Font.Style := fsBold; // Font.Style := [fsBold] in Delphi
Font.Style := fsBold + fsItalic; // Font.Style := [fsBold, fsItalic]
Font.Style := 0; // Font.Style := []
|
DBF Script supports all kind of arrays: static (one- and multi-dimesional), dynamic, variant arrays.
There is an example of script that uses all array types:
var
ar1: array[0..2] of Integer;
ar2: array of Integer;
ar3: Variant;
SetLength(ar2, 3);
ar3 := VarArrayCreate([0, 2], varInteger);
ar1[0] := 1;
ar2[0] := 1;
ar3[0] := 1;
|