Archive

Posts Tagged ‘Visual Studio’

Not loaded. A runtime error occurred during loading of COM add-in

November 22, 2011 2 comments

I’ve spent quite a while trying to sort out why my Word 2007 Add-in won’t work on XP for some time and finally found the problem here …

The add-in is built on .NET 4.0 using VSTO 4.0 and I created a Windows MSI installer but it failed to run on the new XP virtual machine I had created all I got was the following error displayed in the Word Add-Ins dialog:

“Not loaded. A runtime error occurred during loading of COM add-in”

I tried a number of methods to try and identify the problem that are listed here for information before I hit on the actual solution …

1. Ensure all pre-requisites are installed …

  • .NET 4 Client Profile
  • VSTO 4.0
  • 2007 primary interop libraries

I also had one assembly built in VC++ so required the VC++ 2010 x86 redistributable and also a third party component that required VC+ 2008 redistributable too. But even then it wouldn’t work.

2. Next I rebuilt a new add-in that did nothing other than display a messagebox with its own install

Still no joy.

3. I then tried enabling VSTO logging by adding the following system environment variables ..

  • VSTO_SUPPRESSDISPLAYALERTS  = 1
  • VSTO_LOGALLERTS=1

But no amount of searching for *.vsto.logs yielded anything.

4. Next up I enabling Fusion (.NET Framework sub-system for locating and loading assemblies) …

  • Under HKLM\Software\Microsoft\Fusion
  • Create a DWORD value called ForceLog and set 1.
  • Create a String value named LogPath, set the value as c:\fusion
  • Create the C:\fusion folder.

But even then when I ran up Word nothing was displayed!

It just wasnt getting across the com boundary.

5. I went to an old XP virtual machine that’s had all sorts on it …

I installed the add-in and the pre-requisits … and guess what … it WORKED!

Although the old vm had lots installed, the only significant thing was that .NET 3.5 was on there …

Willing to try anything at this stage I returned to the new VM and installed 3.5 …

And … you guessed it … after re-installing the app and the pre-requisits … the add-in sprang into life!!!

Amazed, I did a final search only to find the following link to a “known issue” that Office 2007 tries to load .Net Framework 2.0 before doing anything else …

And what’s more, there is a hotfix available that fixes the issue

http://support.microsoft.com/kb/976477/

Advertisements

VS2010 SP1 Update Failure

If it’s not hard enough to deal with and understand the Microsoft .NET frameowork they go and make their VS upgrade convoluted and buggy!

After what seems like and age the installer throws out an unconvincing error 0x800C0006 and an audit log that goes recursive!

For those who suffer the same or similar plight there is a simple solution … download the SP1 ISO image, mount it on a drive and install as you would have wanted to in the first place!

http://go.microsoft.com/fwlink/?LinkId=210710

The following link gives more information that you might find useful.

http://social.msdn.microsoft.com/Forums/en-US/vssetup/thread/63eb6768-7b78-45fd-8663-b4d7993be563

inTHiNK become a Microsoft BizSpark Partner

November 19, 2010 Leave a comment

inTHiNK is delighted to become the latest Microsoft BizSpark Partner to help support the development of a new social cloud service codenamed “horizon”.

BizSpark_StartUp

We’re delighted at this news as it will allow us access to the full range of Microsoft technologies and cloud services to ensure that “horizon” is a first class resilient cloud service from day 1!

Testing the cloud?

October 25, 2010 Leave a comment

One of my favourite subjects of late is how do you test your cloud?

It’s always been a challenge to get testing more involved in the development process and tooling has come along way to making this possible. But what happens when you add the cloud to the mix?

I’ve had a few chats with Danny Crone from nFocus about this in relation to Azure and was really excited to see they’ve got an event on the very subject …

The only problem is that this takes place tomorrow afternoon in Reading so I can’t make it …

http://testing-with-vs2010-in-the-azure-cloud.eventbrite.com

I only hope that there’s a repeat or that they share some of the presentations …

This sits well with the ALM Health Check Service that inTHiNK is looking to offer in the coming weeks – more on this soon!

Visual Studio Architect Guidance

I got chance to organise an analyst briefing last week at Microsoft to cover the architecture capabilities of Visual Studio 2010. It was a great session as there’s such a strong and exciting story growing for Microsoft in their support not just for architects but right across the Application lifecycle that also reaches out to support development not just of .NET but other languages too which is a great example of Microsoft taking interoperability seriously.

There’s plenty I could talk about, such as UML support and more significant, that you can reverse engineer the likes of sequence diagram directly from your code. Or the architectural explorer and the support for creating layer diagrams with rules that you can then validate your code against plus the support for dependency matrices, and so the list goes on.

However, this raised a slight concern for me that with the growth in tools like these could eventually lead to a significant overhead in learning how to use them. Obviously they are built to be intuitive and easy to use but all the same, the shear volume could become overwhelming.

But as luck would have it the meeting coincided with the release of a codeplex project that provides guidance on how to get the best out of Microsoft’s Architect Tooling in Visual Studio. This has been produced by a set of Microsoft Rangers who have the job it provide out of band solutions for missing features or guidance on the product so you know it’s always going to be useful and based on real-world experiences.

Finally, as this guidance had input from Alan Wills, who has long been synonymous with the world of software modelling, I can’t recommend it highly enough. It’s worth downloading an evaluation copy of VS2010 Ultimate and having a trail if you haven’t already upgraded!

Architect Tooling:
vsarchitectureguide.codeplex.com/

Visual Studio Ultimate:
www.microsoft.com/visualstudio/en-us/products/2010-editions/ultimate