WinBatch Tech Support Home

Database Search

If you can't find the information using the categories below, post a question over in our WinBatch Tech Support Forum.



Can't find the information you are looking for here? Then leave a message over on our WinBatch Tech Support Forum.

Keywords: 	 3132 error when using DAO


I get error 3132 'OLE has not been initialised (or string is missing its quotes)' at the the line...
ws = dao.CreateWorkspace("JetWorkspace", "admin", "")

This error only happens with the compiled code - it works fine from the interpreter (within WinBatch Studio).

I assume I've left something out but can't track it down. Any help would be appreciated.

Sample code

dao = objectopen("DAO.DBEngine.35")
ws = dao.CreateWorkspace("JetWorkspace", "admin", "")
db = ws.OpenDatabase("%WorkDir%ServData.mdb")

sqlstr = "SELECT * FROM SERVER ;"
rs = db.openrecordset(sqlstr)
SServer = rs.fields("Servername")


SServer.value = "%ThisServ%"




  1. Just a thought.... because a similar thing occured with me between the command line and compiled version:

    rather than call the DBEngine directly

    oAPP = OpenObject("Access Application.8")
    DB = oAPP.DBEngine

    then create your workspace.

  2. Another possiblity: Compiler and Interpreter are not the same version number. Possibly using a newer interpreter and an older compiler. Make sure they're the same version by adding ver=Version() to the top of your code and display it in a message box (run it both uncompiled and compiled).

  3. And another possiblity: Compiler code running on a different environment, causing problems. For testing....Put the compiled exe in your WinBatch\System directory and test from there as a logged on user (not a service job or anything). See if it works. If it works, then possibly there is a broken or out-of-date file in your test area, most likely WBO??34I.DLL (If you are using WB2001).

Article ID:   W14425
Filename:   3132 error when using DAO.txt
File Created: 2017:07:28:13:58:31
Last Updated: 2001:12:12:17:16:30