User manual
mikroBasic PRO for PIC32
MikroElektronika
587
IntToStrWithZeros
Prototype
sub procedure IntToStrWithZeros(dim input as integer, dim byref output as
string[6])
Description Converts input integer to a string. The output string is right justied and the remaining positions on the
left (if any) are lled with zeros.
Parameters - input: integer number to be converted
- output: destination string
Returns Nothing.
Requires Nothing.
Example
dim t as integer
txt as string[6]
t = -3276
IntToStrWithZeros(t, txt) ‘ txt is “-03276”
Notes None.
LongWordToStrWithZeros
Prototype
sub procedure LongWordToStrWithZeros(dim input as longword, dim byref output
as string[10])
Description Converts input dword to a string. The output string is right justied and the remaining positions on the
left (if any) are lled with zeros.
Parameters - input: unsigned long number to be converted
- output: destination string
Returns Nothing.
Requires Nothing.
Example
dim t as longword
txt as string[10]
t = 12345678
LongWordToStrWithZeros(t, txt) ‘ txt is “0012345678”
Notes None.