You might get subjected error message when you run some script/vbapplication which interacts with Office products like word, excel, and Outlook through a cron/scheduled job. The reason for failure here is, problem with DCOM permissions. To resolve this issue, follow the below steps.
- Go to the Start-Run menu item.
- Type in “DCOMCNFG” and hit enter.
- This should load the “Component Services” MMC (you can also load from Administrative Tools – Component Services”
- Expand “Component Services”
- Expand “Computers”
- Select “My Computer”
- Select the “DCOM Config” item
- Select the “Microsoft Excel Application” item.
- Right click and select Properties
- Select the Security Tab
- Under “Launch and Activation Permissions” select the “Customize” option.
- Click the “Edit” button
- Click the “Add” button to add the account using which you are running the script/vb application
This should solve your problem. This solution works for all Office applications like Excel, word, and outlook as well. Only thing you need to do is, select respective office application properties instead of Excel in above procedure.
Happy Learning..,
Sitaram Pamarthi