B4J Question Problem with MYSQL connection

ThorstenStueker

Member
Licensed User
B4X:
#Region Project Attributes
    #MainFormWidth: 600
    #MainFormHeight: 600
    
  #AdditionalJar: mysql-connector-java-5.1.47-bin.jar
  
#End Region

Sub Process_Globals
    Private fx As JFX
    Private MainForm As Form
    
    Private Button1 As B4XView
    Private oldbase As SQL
    
End Sub

Sub AppStart (Form1 As Form, Args() As String)
    oldbase.Initialize2("com.mysql.jdbc.MysqlDataSource", "jdbc:mysql://192.168.178.26:3306/HD2000_production?characterEncoding=utf8", "thorsten", "rachel123")
    
    MainForm = Form1
    MainForm.RootPane.LoadLayout("Layout1")
    MainForm.Show
End Sub

Sub Button1_Click
    
End Sub

with Errormessage
 

ThorstenStueker

Member
Licensed User
Got a solution working with initialize async

 
Upvote 0

OliverA

Expert
Licensed User
Longtime User
Btw, this had nothing to do with initialize va initializeasync. The driver class string was incorrect in the first post
 
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…