iOS Question Round B4i Vs Round B4A

MarcoRome

Expert
Licensed User
Longtime User
Hi All.
I have this code:
B4X:
    Dim g_pro As Double
    g_pro = (1300 * (50/100)) / 4
    Log(g_pro)
    Log(Round(g_pro))

And i have this result in B4A ( 163 )


B4i ( 162 )


Any suggestion.
Thank you
 

MarcoRome

Expert
Licensed User
Longtime User

Found Solution:

B4X:
Sub RoundUpNumberFormat(d As Double, integers As Int, fractions As Int) As String
    Return NumberFormat(d + 0.0000001, integers, fractions)
End Sub
 
Last edited:
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…