Zum Inhalt springen
View in the app

A better way to browse. Learn more.

Fachinformatiker.de

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Probleme mit Verbindung von VBA zu MYSQL

Empfohlene Antworten

Veröffentlicht

Hi Leute,

ich hab ein Problem beim Zugriff mit ADO von Excel aus auf eine MySQL-DB. Ich greife auf folgende Weise zu:

Public Sub fillExcelSheetWithMySQLData(strServer As String, strUser As String, strPW As String, _

strDBName As String)

Dim strConn As String

Dim myConn As ADODB.Connection

Dim myRec As ADor.Recordset

Dim r As Integer

Dim c As Integer

Set myConn = New ADODB.Connection

myConn.ConnectionString = _

"Provider=MSDASQL;Driver=MySQL;" & _

"Server=" & CStr(strServer) & ";UID=" & CStr(strUser) & _

";PWD=" & CStr(strPW) & ";database=" & CStr(strDBName) & _

";Option=16386"

myConn.Open

Set myRec = myConn.Execute("select * from mitarbeiter")

For r = 1 To myRec.RecordCount

For c = 0 To myRec.Fields.Count - 1

Tabelle1.Cells(r, c).Value = myRec.Fields®.Value

Next c

Next r

myConn.Close

End Sub

Es handelt sich um kein Treiberproblem(MyODBC 3.51 wurde installiert und der Datenquellenmanager greift selbst problemlos zu) auch das Passwort usw. stimmt.

Muss ich vielleicht in phpMyAdmin noch was einstellen oder könnte die Firewall Probleme machen? (Zugriff erfolgt über localhost)

Wer weiss was?

Fehlermeldung: Microsoft [ODBC Treibermanager] der Datenquellenname wurde nicht gefunden und es wurde kein Standardtreiber angegeben.

mfg

Kajetan

Archiv

Dieses Thema wurde archiviert und kann nicht mehr beantwortet werden.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.