Click here to Skip to main content
13,054,615 members (68,873 online)
Click here to Skip to main content
Add your own
alternative version

Tagged as


Posted 29 Sep 2010

“Error loading pipeline assembly” compile error on Content Projects

, 29 Sep 2010
Rate this:
Please Sign up or sign in to vote.
“Error loading pipeline assembly” compile error on Content Projects

If when trying to compile a Content Project, you see an “Error loading pipeline assembly” message, and don't know why, keep reading...

As you already know, the Content Pipeline always executes locally in your Windows machine, to parse and process all the contents into the XNB files. If you don't have this clear, I'd suggest you read Shawn Hargreaves' blog post. The above error appears sometimes when you add in your Content Project a reference to a Windows Phone Game Library assembly, or to any other platform game library.

I say “sometimes” because this doesn't happen always. For example, it fails on my laptop, but not in my desktop machine (the first is Vista and second is 7, don't know if that has anything to do with it).

The problem is that sometimes (especially since Content Projects where separated from regular projects), you need to reference the same assembly from both a Content Project and from a main game project. For instance, if you store in extra assembly object proxies or descriptions to be used by the XML Intermediate Serializer, you will need them in both the Content Project (to make the serialization), and in the runtime game, to make the de-serialization.

So, if all of them are Windows-XNA based, no problem. But what happens when the main game project is a Windows Phone project? The scenario is:


As I said, if the Aux. Game Library is a Windows Phone game library, for example, it will give you the mentioned compiling problems if you reference it in the Content Project. And if it’s a Windows game library, you won't be able to reference in the Main Game Project, which is a Phone project. How do we solve this?

Creating a Project Copy

Obviously, the solution is to have two different projects/assemblies; one for Windows and another one for WindowsPhone. Of course, as we said that duplicating is wrong, we don't want to duplicate the classes and code in both projects, so the solution is to create a <<project copy>>: an additional project that produces a different assembly type, but that links to the same source files as the other project.

This is an extremely useful feature automated in XNA solutions (you can always do the same manually in other project types). To do so, you just need to right-click in the Solution Explorer, on the project you want to copy, and select:

  • Create a copy of project for Windows
  • Create a copy of project for Windows Phone
  • Create a copy of project for XBox

The task will be done automatically for you. Now you end up with this scenario:


This way, you can keep the Content Project always referencing Windows Game Libraries, and your main Game project referencing the assembly appropriate for each platform, without duplicating code.



This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

Inaki Ayucar
Software Developer (Senior)
Spain Spain
Inaki Ayucar is a Microsoft MVP in DirectX/XNA, and a software engineer involved in development since his first Spectrum 48k, in the year 1987. He is the founder and chief developer of The Simax Project ( and is very interested in DirectX/XNA, physics, game development, simulation, C++ and C#.

His blog is:

To contact Inaki:

You may also be interested in...


Comments and Discussions

-- There are no messages in this forum --
Permalink | Advertise | Privacy | Terms of Use | Mobile
Web02 | 2.8.170713.1 | Last Updated 29 Sep 2010
Article Copyright 2010 by Inaki Ayucar
Everything else Copyright © CodeProject, 1999-2017
Layout: fixed | fluid