Folge dem Video um zu sehen, wie unsere Website als Web-App auf dem Startbildschirm installiert werden kann.
Anmerkung: Diese Funktion ist in einigen Browsern möglicherweise nicht verfügbar.
Public Function db_connect(dbpfad As String) As ADODB.Connection
Dim cn As ADODB.Connection
Set cn = New ADODB.Connection
With cn
.Provider = "Microsoft.Jet.OLEDB.4.0"
.ConnectionString = "Data Source=" & dbpfad
.CursorLocation = adUseClient
.Open
End With
Set db_connect = cn
End Function
Public Function db_recordset(cn As ADODB.Connection, sql As String) As ADODB.Recordset
Dim rs As ADODB.Recordset
Set rs = New ADODB.Recordset
With rs
.Source = sql
.ActiveConnection = cn
.CursorType = adOpenKeyset
.LockType = adLockOptimistic
.Open
End With
Set db_recordset = rs
End Function