Android Question MSSQL Boolean problem

Tomas Petrus

Active Member
Licensed User
Longtime User
Hi,

I am using this tutorial with HttpUtils2 and everything is working perfectly, but I have problem with bool variable.
I have this code:

B4X:
Dim Start = False As Boolean

If  m.Get("Start") = Null Then
      Start = False
Else
     Start = m.Get("Start")
End If

Log(Start)      
If Start = True Then 
     'Do something
  Else
     'Do something else
End If


Sometimes I get NullPointerException in "If Start = True Then", but it should not be possible and in log is "false" so variable isn't Null. It is really wierd, because it does not happen everytime.

Thanks for Answer!
 

Tomas Petrus

Active Member
Licensed User
Longtime User
I changed only count of records in database. With one record it is fine, but with more is there that exception

Thanks!
 
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…