Char PowerScript function
Description
Extracts the first Unicode character of a string or
converts an integer to a char.
Syntax
|
1 |
<span>Char</span> ( <span>n</span> ) |
|
Argument |
Description |
|---|---|
|
n |
A string that begins with the character |
Return Values
Char. Returns the first Unicode character
of n. If n is null, Char returns null.
Examples
This example sets ls_S to
an asterisk, the character corresponding to the ASCII value 42:
|
1 |
string ls_S |
|
1 |
ls_S = <span>Char</span>(42) |
These statements generate delivery codes A to F for
the values 1 through 6 of li_DeliveryNbr:
|
1 |
string ls_Delivery |
|
1 |
integer li_DeliveryNbr |
|
1 |
|
1 |
FOR li_DeliveryNbr = 1 to 6 |
|
1 |
ls_Delivery =<span> Char</span>(64 + li_DeliveryNbr) |
|
1 |
... // Additional processing of ls_Delivery |
|
1 |
NEXT |
See Also
Document get from Powerbuilder help
Thank you for watching.
Subscribe
Login
0 Comments
Oldest