Previous Topic Next topic Print topic


&SUBST-ALL

Holds the original string along with all occurrences of the match string replaced by the substitute string. If the match string does not occur in the original string, &SUBST returns a copy of the original string. The original arguments remain unchanged.
Restriction: This topic applies only when the AppMaster Builder AddPack has been installed, and applies only to Windows platforms.

Syntax:

&SUBST-ALL ('originalstring', 'matchstring', 'substitutestring')

Aliases:

&subst-all ('originalstring', 'matchstring', 'substitutestring')
&Subst-All ('originalstring', 'matchstring', 'substitutestring')
&SUBSTALL ('originalstring', 'matchstring', 'substitutestring')
&substall ('originalstring', 'matchstring', 'substitutestring')
&SubstAll ('originalstring', 'matchstring', 'substitutestring')
&SUBSTITUTE-ALL ('origstring', 'matchstring', 'substitutestring')
&substitute-all ('origstring', 'matchstring', 'substitutestring')
&Substitute-All ('origstring', 'matchstring', 'substitutestring')
&SUBSTITUTEALL ('origstring', 'matchstring', 'substitutestring')
&substituteall ('origstring', 'matchstring', 'substitutestring')
&SubstituteAll ('origstring', 'matchstring', 'substitutestring')

Comments:

If any of the arguments are stored as a numeric type, MFG converts them to a temporary text form before performing the matching process.

Examples:

&SUBST-ALL ("ABCDEFABCDEF", "ABC", "xyz") = "xyzDEFxyzDEF"
&SUBST-ALL ("ABCDEFABC", "ABC", "uvwxyz") = 
% ... "uvwxyzDEFuvwxyzDEF"
&SUBST-ALL ("ABCDEFABCDEF", "ABC", "xyz") = "xyzDEFxyz"
&SUBST-ALL ("ABCDEFABCDEF", "ABC", "")    = "DEFDEF"
&SUBST-ALL ("ABCDEFABCDEF", "", "XYZ")    = "ABCDEFABCDEF"
Previous Topic Next topic Print topic