Click or drag to resize

StrInt Function

X#
Convert an integer expression to a PSZ.

Namespace:  XSharp.RT
Assembly:  XSharp.RT (in XSharp.RT.dll) Version: 2.19
Syntax
 FUNCTION StrInt(
	liNumber AS LONG,
	dwLength AS DWORD,
	dwDecimals AS DWORD
) AS STRING
Request Example View Source

Parameters

liNumber
Type: Long
The integer expression to convert.
dwLength
Type: DWord
The length of the string to return, including decimal digits, decimal point, and sign.
If dwLength is not long enough to hold the entire number, the result will be in scientific notation.
dwDecimals
Type: DWord
The number of decimal places to return.

Return Value

Type: String
Remarks
StrInt() is a typed version of the Str() numeric function, except that SetDecimalSep() is ignored. See Str() for a detailed description.
Examples
These examples demonstrate the range of values returned by StrInt(), depending on the arguments specified:
X#
1LOCAL iNumber AS INT
2iNumber := 123
3? StrInt(iNumber,10, 0)            // 123
4? StrInt(iNumber, 4, 0)            // 123
5? StrInt(iNumber, 2, 0)            // **
See Also