更新 vbalinkmysql.txt
This commit is contained in:
parent
03a770d055
commit
a3436b59ad
|
@ -27,12 +27,12 @@ Public Sub AutoRun()
|
||||||
|
|
||||||
If VBA.Err.Number <> 0 Then
|
If VBA.Err.Number <> 0 Then
|
||||||
strDBinf = "DSN=mysqlinklexcel64" '标准语句
|
strDBinf = "DSN=mysqlinklexcel64" '标准语句
|
||||||
VBA.MsgBox "32位DSN连接失败,尝试使用mysqlinklexcel6连接!"
|
VBA.MsgBox "32位DSN连接失败,尝试使用mysqllinkexcel6连接!"
|
||||||
Call conn.Open(strDBinf)
|
Call conn.Open(strDBinf)
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If VBA.Err.Number > 1 Then
|
If VBA.Err.Number > 1 Then
|
||||||
VBA.MsgBox "连接异常,请检查DB环境!"
|
VBA.MsgBox "连接异常,请检查DB环境!"
|
||||||
Set conn = Nothing
|
Set conn = Nothing
|
||||||
End If
|
End If
|
||||||
Application.StatusBar = "数据库连接成功"
|
Application.StatusBar = "数据库连接成功"
|
||||||
|
|
Loading…
Reference in New Issue