Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
Private Sub Command1_Click()
Dim je As New JRO.JetEngine, srcdb As String, string1 As String, string2 As String, strfrom As String, strto As String, strKillfile As String
srcdb = Text1
If Option97 = True Then
string1 = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & srcdb & ";Jet OLEDB:Engine Type=4"
string2 = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & Left(srcdb, Len(srcdb) - 4) & "2k.mdb;Jet OLEDB:Engine Type=5"
strto = "2K"
strfrom = "97"
strKillfile = Left(srcdb, Len(srcdb) - 4) & "2k.mdb"
Label1 = "Converting from " & strfrom & " format to " & strto
If Dir(strKillfile) <> "" Then Kill (strKillfile)
je.CompactDatabase string1, string2
Label1 = "Converted to " & Left(srcdb, Len(srcdb) - 4) & string3 & ".mdb"
Else
string1 = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & srcdb & ";Jet OLEDB:Engine Type=5"
string2 = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & Left(srcdb, Len(srcdb) - 4) & "97.mdb;Jet OLEDB:Engine Type=4"
strfrom = "2K"
strto = "97"
strKillfile = Left(srcdb, Len(srcdb) - 6) & "97.mdb"
'je.CompactDatabase string1, string2
je.CompactDatabase "PROVIDER=Microsoft.Jet.OLEDB.4.0;Data Source=" & srcdb & ";Jet OLEDB:Engine Type=5", "PROVIDER=Microsoft.Jet.OLEDB.4.0;Data Source=" & Left(srcdb, Len(srcdb) - 4) & "97.mdb" & ";Jet OLEDB:Engine Type=4"
'dbE.CompactDatabase srcdb, strKillfile, dbLangGeneral, dbVersion30
Label1 = "Converted to " & Left(srcdb, Len(srcdb) - 4) & string3 & ".mdb"
End If
End Sub