Windows10 MySQL community server problems

MySQL community server problems
Apps I have distributed don’t work under Windows10. They hang just stating there is a problem.
What I dit to find out what the cause: I builded an OSX version > No problem. Than I made an new Winows (32bit) App from scratch and added functionality, tested the version and added a new one.

It appears the following code is the cause:

Dim DB As New MySQLCommunityServer

If DB.Connect then
MsgBox “Connected”
Else
DB = New MySQLCommunityServer

DB.Host = DB_path
DB.port = DB_port
DB.DatabaseName = DB_name
DB.UserName = DB_user_name
DB.Password = DB_user_pw

End IF

If DB.Connect then
MsgBox “Connected”
Else
MsgBox “Geen dataconnectie!”
End If

The code in my previous message is on App.module level. This worked fine onder Windows7. But Windows10 seams to dislike this way of working.

As usual after a lot of search work the outcome is evident …

Dim DB As New MySQLCommunityServer was already done as an property … So the Nil state of it was crucial!

If DB <> NIL then
// MsgBox “Connected”
Return True
Else
DB = New MySQLCommunityServer

Ah so you had a local shadowing the modules property ?

Yep … An seconde App.public in fact. And the old underlying code was tolerant to this messy work by me. The new Win10 stuff is not!
But as usual with systematic deducting the way out is clear and obvious … :wink: