String Operations

<< Click to Display Table of Contents >>

Navigation:  3. Script Language > String commands > !STR.- String Command >

String Operations

STR.GrabQuoted

Previous Top Next


MiniRobotLanguage (MRL)

 

STR.GrabQuoted

Extract Quoted Terms from a String

 

 

Intention

 

This command extracts a quoted term from a source string based on its index.

The result is either placed on the Top of Stack (TOS) or in an optional variable.

 

 

 

 

Syntax

 

 

STR.GrabQuoted|P1|P2[|P3][|P4]

 

 

 

Parameter Explanation

 

P1 - (Source String) The string from which to extract the quoted term.

P2 - (Index) The index of the quoted term to extract.

P3 - (Optional) Alternate quote character. Default is ASCII(34).

P4 - (Optional) Variable for storing the result. If omitted, the result is placed on TOS.

 

 

 

 

Example

 

'***********************************

' STR.-Sample

'***********************************

$$SRC="Hello 'World' 'MiniRobot'!"

$$IDX=2

$$QUO='

STR.GrabQuoted|$$SRC|$$IDX|$$QUO|$$RES

DBP.$$RES

ENR.

 

 

 

 

 

 

Remarks

 

-

 

 

Limitations:

 

-

 

 

See also: