11.07.2015 Views

Caché ObjectScript Reference - InterSystems Documentation

Caché ObjectScript Reference - InterSystems Documentation

Caché ObjectScript Reference - InterSystems Documentation

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

System and Other Functions$ZISWIDEChecks whether a string contains any 16-bit wide characters.$ZISWIDE(string)$ZIS(string)ParametersstringA string of one or more characters, enclosed in quotation marks.Description$ZISWIDE is a boolean function used to check whether a string contains any 16-bit widecharacter values. It returns one of the following values:01All characters have ASCII values 255 or less (8-bit characters). A null string ("")also returns 0.One or more characters have an ASCII value greater than 255 (wide characters).Note that in a Unicode version of <strong>Caché</strong>, all characters are 16-bits in length. $ZISWIDEchecks the character values to determine if they are in the ASCII range (0-255), and thuscould be represented by 8 bits, or in the wide character range (256-65535) and thus use all16 bits of the Unicode character.ExampleThe first two examples test strings that contain all narrow (8-bit) character values and return0. The third example tests a string containing a wide character value (the second character),and therefore, returns 1:WRITE !,$ZISWIDE("abcd")WRITE !,$ZISWIDE($CHAR(71,83,77))WRITE !,$ZISWIDE($CHAR(71,300,77))See Also• $ZPOSITION function• $ZWASCII function• $ZWCHAR function• $ZWIDTH function544 <strong>Caché</strong> <strong>ObjectScript</strong> <strong>Reference</strong>

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!