Thursday, August 2, 2007

Removing Norton SystemWorks causes problems with Office Automation

This was a tough problem to uncover... so tough that I think it really should be documented. I develop and support some VB.NET 2.0 software which uses Microsoft Word Automation. One user sent me an email with a problem that occurs on his machine when this Word Automation functionality takes place.

This is the error as it was reported:
System.IO.FileNotFoundException: Retrieving the COM class factory for component with CLSID {000209FF-0000-0000-C000-000000000046} failed due to the following error: 8007007e.

I didn't know what was going on but my first suggestion was to try a Word "Detect and Repair." This didn't solve the problem. So I was left to searching Google for potential solutions. I was researching and researching for a couple hours and my hopes were fading.

Then I found something. I found a case where somebody had to manually remove Norton Antivirus, but Norton left behind a registry entry with a bad reference. In this case this bad reference also caused a problem with Office Automation. I thought I might be onto something here. So I asked the user I was trying to help about this and sure enough, he too had Norton installed at one point but had since removed it. At this point I was feeling a bit like Dr. House diagnosing complex medical problems in the show conveniently named, "House."

This user seemed very comfortable with his computer so I asked him to go to the following location in his registry and export and email it to me:
\HKEY_CLASSES_ROOT\CLSID\{000209FF-0000-0000-C000-000000000046}\

The settings here are critical to the operation of Microsoft Word. So I took a good look at his registry settings and found the registry entry of consequence resides at:
\HKEY_CLASSES_ROOT\CLSID\{000209FF-0000-0000-C000-000000000046}\InprocServer32

The (Default) string in this location was "C:\\Program Files\\Common Files\\Symantec Shared\\Script Blocking\\ScrBlock.dll". I had the user double check to ensure that this dll doesn't exist in that physical location. It didn't so I had him right-click that (Default) value and delete it. This solved the problem!

Now apparently Norton can be notoriously difficult to remove completely. I had problems with this myself last year. I don't know if it's typical, or if it only happens when your computer happens to be infected and your Norton installation is crippled, or just what. But in this case it obviously left behind stray information which caused this problem.

Hopefully what I've learned today will be helpful for someone else.