I just can not found how to do it, I have browsed docs for hour or two..
Dim expiryTime As Long
expiryTime = 14400000
Log("expiryTime: " & expiryTime) ' gives -> "1.44E7" I want proper "14400000"
Is Long primitive or object in b4a ?? expiryTime does not have any methods and I cant find any math or string util that gives me right presentation of Long
Edit2: Int "14400000" prints correctly, but I need Long
Edit3: I get to nowhere with this
.... if I set Label1.Text = expiryTime, it prints correctly there...
.
Edit4:
Try this:
Dim expiryTime As Long
Dim testString As String
expiryTime = 14400000
Log("expiryTime: " & expiryTime)
Label1.Text = expiryTime
testString = expiryTime
Log("testString1: " & testString)
testString = Label1.Text
Log("testString2: " & testString)
And you get:
expiryTime: 1.44E7
testString1: 1.44E7
testString2: 14400000
Edit.5: Bug seems to be in b4a internal method ---->>>> _teststring = BA.NumberToString(_expirytime); But I cant dig any deeper to b4a as I'm too lazy to decompile bunch of java classes just to find that BA.NumberToString()...
Edit.6: Thanks for quick fix!
Dim expiryTime As Long
expiryTime = 14400000
Log("expiryTime: " & expiryTime) ' gives -> "1.44E7" I want proper "14400000"
Is Long primitive or object in b4a ?? expiryTime does not have any methods and I cant find any math or string util that gives me right presentation of Long
Edit2: Int "14400000" prints correctly, but I need Long
Edit3: I get to nowhere with this
.
Edit4:
Try this:
Dim expiryTime As Long
Dim testString As String
expiryTime = 14400000
Log("expiryTime: " & expiryTime)
Label1.Text = expiryTime
testString = expiryTime
Log("testString1: " & testString)
testString = Label1.Text
Log("testString2: " & testString)
And you get:
expiryTime: 1.44E7
testString1: 1.44E7
testString2: 14400000
Edit.5: Bug seems to be in b4a internal method ---->>>> _teststring = BA.NumberToString(_expirytime); But I cant dig any deeper to b4a as I'm too lazy to decompile bunch of java classes just to find that BA.NumberToString()...
Edit.6: Thanks for quick fix!
Last edited: