Can't find the information you are looking for here? Then leave a message over on our WinBatch Tech Support Forum.
Keywords: 1129 OleInitiate Failed UAC Windows 7 Win7 64 bit Excel Excel.Application
xl = ObjectGet(,"Excel.Application")But on my Windows 7 64 bit PC, that exact same code returns an error ... 1129: OleInitiate: Initiate Failed even though I have Excel running and have a workbook open.
Does anyone know what might have changed in Excel v14 or how can I get a handle to an running instance of Excel now?
Details:
By default when Excel is started by an admin user it has the low privilege admin security token while a WinBatch script with the '.wbt' file extension starts with the admin elevated token so the two have different security tokens and the script is blocked from accessing the Excel ROT object.
In order to make your script work, you would need to compile the accessing script as 'AsInvoker'/'False', change the uncompiled script's extension from '.wbt' to '.wbt_if', or run Excel with full admin privileges and run your script with the same privileges.
Another approach might be to investigate Excel's COM related security settings and see if there is a way to change them to allow 'Any Client' access to the ROT object. Of course, this approach can be problematic if you plan on distributing your script to others because you would need to insure that all machines have the desired settings.
Article ID: W18013
Filename: 1129 OleInitiate Failed UAC .txt
File Created: 2013:08:26:09:06:34
Last Updated: 2013:08:26:09:06:34