Windows Phone 7 – one fix for “Xap packaging failed. Object reference not set to an instance of an object.”

I faced that error while building a WP7 app after doing some reorganization of files within the solution.

VS2010 didn’t give any pointers, so i turned to Google and found this post in Jayway Team’s blog. My problem was not exactly the same, but that post pointed me to the right direction. Thank you to Jayway Team!

I had accidentally moved the default “ApplicationIcon.png” and “BackGround.png” from the root of the solution to a resources folder. After a bit of digging around the solution, i found the references to those images in the WMAppManifest.xml-file located within properties folder.

Issue went away by altering the paths. Really simple, but why-oh-why VS couldn’t give me any useful information right at the beginning…

Advertisements

10 thoughts on “Windows Phone 7 – one fix for “Xap packaging failed. Object reference not set to an instance of an object.”

  1. I’ll jump on the bandwagon. I’d renamed some files in my source control and created some new background images for my live tile and there were still some files “included in the project” that were no longer there. I was ready to spend the day restoring previous versions and recreating all the changes I’d made in the last 24 hours, but 5 minutes after reading your post, I was back in good working order!

    Thanks!

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s