Passing characters
Passing chars to WinAPI
WinApi characters can have ANSI or Unicode values, while PowerBuilder
characters have only Unicode values. ANSI Char values
passed to and from WinAPI calls are automatically converted by PowerBuilder.
Therefore, when defining character array length, you must always
use the PowerBuilder character length (two bytes per character).
Passing chars to C functions
Char variables passed to external C functions are
converted to the C char type before passing.
Arrays of Char variables are converted to the
equivalent C array of char variables.
An array of Char variables embedded in
a structure produces an embedded array in the C structure. This
is different from an embedded String, which results
in an embedded pointer to a string in the C
structure.
Whenever possible, pass String variables
back to PowerBuilder as a return value from the function.