VBScript & Access MDB - 800A0E7A - “Provider cannot be found. It may not be properly installed”

后端 未结 7 808
心在旅途
心在旅途 2020-11-28 14:29

I\'ve having a problem with a VBScript connecting to an access MDB Database. My platform is Vista64, but the majority of resources out there are for ASP/IIS7.

Quite

7条回答
  •  抹茶落季
    2020-11-28 14:57

    I used this it worked for me without any error:

    sconnect = "Provider=MSDASQL.1;DSN=Excel Files;DBQ=" & myPath & ";HDR=Yes';"
    Set con = CreateObject("ADODB.Connection")
    Set rs = CreateObject("ADODB.Recordset")
    
    con.Open sconnect
    sSQLQry = "SELECT * FROM [" & tableName & "];"
    Set rs = con.Execute(sSQLQry)
    

提交回复
热议问题