Codex API: Types


COMMATEXT is a pointer to a null terminated string. COMMATEXT contains a list of strings in system data format (SDF). All Codex API functions which pass a collection of strings use the COMMATEXT format.


COMMATEXT contains a collection of multiple strings in a single comma-delimited string. For example, the collection of the following strings:

Stri,ng 1
Stri"ng 2
String 3

will be represented as the following single string:

"Stri,ng 1","Stri""ng 2","String 3",String4

COMMATEXT values are parsed as SDF formatted text. For SDF format, strings are separated by commas or spaces, and optionally enclosed in double quotes. Double quote marks that are part of the string are repeated to distinguish them from the quotes that surround the string. Spaces and commas that are not contained within double quote marks are delimiters. Two commas next to each other will indicate an empty string, but spaces that appear next to another delimiter are ignored. For example, suppose we have the following COMMATEXT representation:

"Stri,ng 1", "Stri""ng 2" , String 3,String4

The actual list of strings will then be:

Stri,ng 1
Stri"ng 2

See Also

Codex API Overview, Codex API Functions