How to fix Error Getting Design Time Data in Blend with MVVM-Light

I ran in to this recently and couldn’t find anything online about it.

Using MVVM-Light for Windows Phone development and Blend. It works fine in Visual Studio, but every time I open one of my pages in Blend I get this error. 

Blend Error: Class is already registered. mvvm-light in Blend

Already registered? I’m using MVVM-Light’s integration with a Simple IoC container to manage my dependencies and so it really leaves me wondering what’s going on here. I know that I only registered this class once.. so what gives?

Fortunately for me, Laurent (the creator of MVVM-Light, fellow MVP, and all around Blend Ninja) is active on Twitter and saw my tweet.

image

image

image

image

hmm.. let’s try that…

image

and ta-day!

image

Design time data working in Blend using MVVM-light!.

Special thanks to Laurent for knowing exactly what I needed to do. Thanks my friend!

About Caleb Jenkins

Caleb Jenkins is an international speaker, author and 6 time Microsoft MVP award recipient. An entertaining and informative speaker that approaches software from a fresh perspective that spans UX, Agile and enterprise customers from across the globe. He has previously led UX product design teams, coached multi team agile transformations and architected and mentored at some of the largest companies in the world. As a long time community leader and former Microsoft Developer Evangelist Caleb is well known for his engaging speaking style, depth of knowledge and creative energy. Founder and Principal Mentor at Proaction Mentors, former UX Manager and Agile Coach for Sabre, former Senior Architect for Six Flags Corporation, Caleb currently helps agile development teams working with Slalom Consulting in Dallas. You can follow him on twitter (@calebjenkins) or his blog, DevelopingUX.com and if you're still reading this, then you could also subscribe to his blog RSS feed or sign up to receive updates by email