Eugene Starostin

A bit about Microsoft Office PIA

Today I’m overwhelmed with inspiration. Don’t know how to cope with it. Hey, somebody, stop me! :-) All in all, I’ve come to one of the key issues. What is the Office PIA and what should we do with it? To start with, a few words about PIAs, primary interop assemblies.

There was OLE first, remember? Next there’s OLE Automation. After that came COM, DCOM and COM+. Do you remember what type libraries ITypeInfo and ITypeInfo2 are? A PIA is, in fact, a COM type library imported to .NET. But not to IDL. PIA is much more comfortable to use because it is a set of .NET classes that wrap all interfaces of a COM type library. And an Office PIA is an imported MS Office type library. For more details, please see the links below. I will just say that they are very easy to use. All in all, I recommend.

However, there’s one problem here. There are official PIAs for Office XP and Office 2003 published by Microsoft. For Office 2000 there’re no official PIAs. Meanwhile, Microsoft says:

Microsoft does not guarantee that the Office PIA will be backwardly compatible or that the Office XP PIA and the Office 2003 PIA can be run side-by-side in the same instance of an Office application. Office XP managed code add-ins must be built against the Office XP PIAs. The Office 2003 managed code add-ins must be built against the Office 2003 PIAs. Therefore, if you build an add-in solution that you intend to use with both versions of Office, Microsoft recommends that you build a version of your add-in for each version of Office that you intend to support.

Scaring, isn’t it? But do you want to create special versions of your add-in for Office 2000, XP, 2003 and 2007? Or have you customers already upgraded their Office to 2007? I answered this question long ago. I use Office 2000 PIAs generated by myself for add-ins that must work in all available versions of Microsoft Office. If the add-in is to work in Office XP and higher, I use the official Office XP PIAs. And it works in spite of the fact that Microsoft doesn’t guarantee it. I know the reasons why it is no guaranteed. But I will not tell you about them, because my inspiration has run dry. Today I was helped by Mark Knopfler from his Shangri-La. :-)

Last updated on 10-Jun-2013.
Now Add-in Express for Office and .net provides the PIA mentioned above to allow the developer to create COM add-ins that support all Office versions across 2000 through Office 2013 32-bit and 64-bit.

For more information about the correct usage of interop assemblies, please see: Supporting
several Office versions in an add-in. Interop assemblies and late binding

Related links

Working with the Office XP Primary Interop Assemblies:

Installing and Using the Office 2003 Primary Interop Assemblies:

Download Official Office 2003 PIAs:;en-us;897646

Download Official Office XP PIAs:

Related posts:

Add-in Express .NET and Microsoft Office PIAs


  • raghav says:

    I want to install 0ffice 2003 PIA using BootStrapper.
    I had a problem that,

    Iam using the following link in Product.xml. “”
    So it not downloading “o2003pia.msi” from the above url and throwing the following error.

    Setup has detected that the file ‘C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\VSDB7.tmp\O2003PIA\O2003PIA.msi’ has either changed since it was initially published or may be corrupt.

    Please suggest me in finding the solution for this problem

  • Andrei Smolin (Add-in Express Team) says:

    See how Microsoft recommend deploying PIAs at

  • Rodrigo says:

    I got a question. I got a couple of old VB6 (very old i know) apps that uses office 2003/xp object libs, what would happend with the apps when we move all park to office 2007? would i need to recompile all apps with new 2007 object libs (if ther is one)? or will it still work even with the oll references to 2003/xp object libs? Can i have office 2003 and 2007 on the same machine, would that work and make the apps still work?

    We are currently using office 2003 on all machines, and since the code is very very old they do not use PIAs (and is a VB6 app).


  • Andrei Smolin (Add-in Express Team) says:

    Office applications are almost 100% backward compatible. If a VB6 standalone appliction project is compiled against a certain Office version, then it will work with all newer Office versions.

Post a comment

Have any questions? Ask us right now!