N
Nate
(Apologies if this has been covered before)
I have several scripts that automate the creation of Excel workbooks,
that are kicked off by the SQL Server Agent. Up until today,
everything ran as expected. However, today, the scripts were failing
silently. I went to check the DCOM permissions (dcomcnfg), but when I
selected "Microsoft Excel Application" from the list and clicked the
Properties button, I got a message box saying "The operation completed
successfully", and an OK button - not the Properties tabs I was
expecting.
According to MS KB article 288367 (http://support.microsoft.com/kb/
288367), "How to configure Office applications to run under a specific
user account", the following registry key should exist:
Key: HKEY_CLASSES_ROOT\AppID\EXCEL.EXE
AppID: {00020812-0000-0000-C000-000000000046}
I mis-read this, and thought it meant to create the registry key:
HKEY_CLASSES_ROOT\AppID\{00020812-0000-0000-C000-000000000046}
which I did, and that was the solution, my scripts started working
again! I tried deleting my 'incorrect' key: scripts stop working.
Tried putting in the 'correct' MS key: scripts not working. Put in
the 'incorrect' key again: scripts work ok!
So really, I'm posting this (a) because it might help someone in the
future, and (b) to ask if anyone has any ideas WHY this problem might
have occurred, and why the MS suggestion doesn't work, but my mis-
reading of it does!
(Normally, I expect problems after an MS update, but that wasn't the
case here, so I'm even more intrigued than normal...!)
Regards,
Nate
I have several scripts that automate the creation of Excel workbooks,
that are kicked off by the SQL Server Agent. Up until today,
everything ran as expected. However, today, the scripts were failing
silently. I went to check the DCOM permissions (dcomcnfg), but when I
selected "Microsoft Excel Application" from the list and clicked the
Properties button, I got a message box saying "The operation completed
successfully", and an OK button - not the Properties tabs I was
expecting.
According to MS KB article 288367 (http://support.microsoft.com/kb/
288367), "How to configure Office applications to run under a specific
user account", the following registry key should exist:
Key: HKEY_CLASSES_ROOT\AppID\EXCEL.EXE
AppID: {00020812-0000-0000-C000-000000000046}
I mis-read this, and thought it meant to create the registry key:
HKEY_CLASSES_ROOT\AppID\{00020812-0000-0000-C000-000000000046}
which I did, and that was the solution, my scripts started working
again! I tried deleting my 'incorrect' key: scripts stop working.
Tried putting in the 'correct' MS key: scripts not working. Put in
the 'incorrect' key again: scripts work ok!
So really, I'm posting this (a) because it might help someone in the
future, and (b) to ask if anyone has any ideas WHY this problem might
have occurred, and why the MS suggestion doesn't work, but my mis-
reading of it does!
(Normally, I expect problems after an MS update, but that wasn't the
case here, so I'm even more intrigued than normal...!)
Regards,
Nate