petr4ppc Well-Known Member Licensed User Longtime User Jan 30, 2020 #1 Dear friends, In process_globals I have: B4X: Dim myulongvalue As ULong via JSON I get: B4X: GetTextValueFromKey(jsontext, "myvalue", 0, buffer, MaxSize) Dim ii As String = bc.StringFromBytes(buffer) Log("Value is =",ii) I am reading right value in log: 16766032 but how can I convert this value to Ulong, please? B4X: myulongvalue = ii Best regards p4ppc Last edited: Jan 30, 2020
Dear friends, In process_globals I have: B4X: Dim myulongvalue As ULong via JSON I get: B4X: GetTextValueFromKey(jsontext, "myvalue", 0, buffer, MaxSize) Dim ii As String = bc.StringFromBytes(buffer) Log("Value is =",ii) I am reading right value in log: 16766032 but how can I convert this value to Ulong, please? B4X: myulongvalue = ii Best regards p4ppc
thetahsk Active Member Licensed User Longtime User Jan 30, 2020 #2 Casting a String Number to Ulong B4X: Dim NumberUlong As Ulong = StringNumber Upvote 0
petr4ppc Well-Known Member Licensed User Longtime User Jan 31, 2020 #3 Dear thetahsk Thank you very much for your help. Its solved. Best regards p4ppc Upvote 0