CRE Programmer's Guide
String and Memory Block Functions
Common Run-Time Environment (CRE) Programmer’s Guide—528146-004
8-9
Stci_D
Stci_D
The Stci_D functions convert a signed integer to a string of decimal characters. These 
functions are not available in the native CRE library. 
str
is a pointer to the converted decimal string.
integer
is the integer to convert.
max_bytes
is the size of the buffer, str, provided for the conversion.
Return Value
The Stci_D functions return the length of the resulting string, excluding the terminating 
null character.
Considerations
•
The Stci_D functions do not store leading zeros in the output string. 
•
The output string is terminated with a null byte.
•
If integer is negative, the output string is preceded by a minus sign.
•
If integer is zero, a single zero character is stored.
•
The buffer at str must be large enough to hold a minus sign, if integer is 
negative, plus the converted number, and a null byte. 
If there are more than 
max_bytes to store, the Stci_D functions store the minus 
sign if 
integer is negative, followed by as many bytes as will fit while still storing 
a null character at the end of 
str. 
INT PROC RTL_Stci_D_( str, integer, max_bytes );
 STRING .str; ! out
 INT integer; ! in
 INT max_bytes; ! in TNS only
INT PROC RTL_Stci_DX_( str, integer, max_bytes );
 STRING .EXT str; ! out
 INT integer; ! in
 INT max_bytes; ! in TNS only










