Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

 

You will note that some Action properties are of type TStrings. TStrings is a standard Delphi type that we have exposed to the scripting engine. It is basically a string collection. Below are the properties of TStrings that you will find useful:

 

   procedure Clear;

   function Add(const S: string): Integer;

...

   property Names[Index: Integer]: string;  // used to access the name of a string which is of the format Andlt;nameAndgt;=Andlt;valueAndgt;<name>=<value>

   property Values[Index: String]: string;  // used to access the value of a string which is of the format Andlt;nameAndgt;=Andlt;valueAndgt;<name>=<value>

   property ValueFromIndex[Index: Integer] : string; // used to access the value of a string which is of the format Andlt;nameAndgt;=Andlt;valueAndgt;<name>=<value>

 

Example:

The following code reduces each item in a List Iterator's list of items down to its leftmost three characters: