WinBatch® Technical Support Forum

All Things WinBatch => WinBatch => Topic started by: MW4 on February 14, 2018, 10:53:38 AM

Title: Access code broke today
Post by: MW4 on February 14, 2018, 10:53:38 AM
I believe it was a security patch

Now I get an error here:

Access = ObjectOpen("Access.Application")

I'm uninstalling updates one by one, will keep you all posted
Title: Re: Access code broke today
Post by: MW4 on February 14, 2018, 11:08:29 AM
Error is OLE initiate failed
Title: Re: Access code broke today
Post by: stanl on February 14, 2018, 12:12:42 PM
I feel your pain.  Just a SWAG but you might need oAccess = ObjectOpen("Access.Application.#")  where # is the version of Access/Office and the oAccess is just in case there is a syntax issue, but more likely you have some major corruption and rebuilding is the answer.
Title: Re: Access code broke today
Post by: td on February 14, 2018, 01:15:52 PM
You may get lucky and just need to re-register the Access COM server to fix some kind of registry corruption.
Title: Re: Access code broke today
Post by: MW4 on February 14, 2018, 01:20:25 PM
It's not an Access database issue, they are fine and not corrupted WBT just can't initiate OLE in order to insert rows into the database.
References are ok. Microsoft Office 2016 installed a bunch of updates. I uninstalled them all, but the issue persists.

I'm going to try your version solution, but what's the oAccess vs Access?
Title: Re: Access code broke today
Post by: MW4 on February 14, 2018, 01:23:14 PM
How do I do that re-register the Access COM server ?
Title: Re: Access code broke today
Post by: td on February 14, 2018, 02:09:58 PM
Quote from: MW4 on February 14, 2018, 01:20:25 PM
It's not an Access database issue, they are fine and not corrupted WBT just can't initiate OLE in order to insert rows into the database.
References are ok. Microsoft Office 2016 installed a bunch of updates. I uninstalled them all, but the issue persists.

I'm going to try your version solution, but what's the oAccess vs Access?

No one said it was an "Access database issue" nor that your databases are corrupt.  WinBatch can't initiate the Access Com Automation object which is the result of something completely different.  If you are lucky the cause of the latter is as previously mentioned deleted or corrupt registry entries.  Corrupt registry entries are an all to common problem of Microsoft's never-ending stream of updates.
Title: Re: Access code broke today
Post by: MW4 on February 14, 2018, 02:14:06 PM
Was just ruling them out...as Access has a reputation of corruption.
So how do I re register the Access COM server ?
Title: Re: Access code broke today
Post by: td on February 14, 2018, 02:28:46 PM
You fire up your favorite Web search engine and find out how to use the command line tool. You will likely find something like the following:

https://technet.microsoft.com/en-us/library/bb490985.aspx (https://technet.microsoft.com/en-us/library/bb490985.aspx)

And then you figure out the name and location of the dll or exe you need to register.  In this case, it may simply be <wherever that happens to be installed on your system> "MSACCESS.EXE".

There is no guarantee that this will fix your problem but it has a high enough probability of success to at least give it a try. 
Title: Re: Access code broke today
Post by: td on February 14, 2018, 02:47:45 PM
Forgot to add the usual warning that you should backup your registry before making any changes...
Title: Re: Access code broke today
Post by: MW4 on February 14, 2018, 03:41:25 PM
Changing to Access.Application.15 doesn't work

trying to register msaccess.exe and getting Entry Point Not Found

ran a SFC /Scannow, no go.

I'm trying an office reinstall
Title: Re: Access code broke today
Post by: MW4 on February 14, 2018, 05:02:43 PM
That did it...an office online repair.

What a pain in the rear day
Title: Re: Access code broke today
Post by: td on February 15, 2018, 07:39:06 AM
At least it's fixed.