Aaron Stebner's WebLog

Thoughts about setup and deployment issues, WiX, XNA, the .NET Framework and Visual Studio

How to work around a possible XNA Game Studio or Windows Phone SDK install failure on Windows 8

How to work around a possible XNA Game Studio or Windows Phone SDK install failure on Windows 8

Rate This

If you try to install the Windows Phone SDK 7.1 or XNA Game Studio on Windows 8, you may encounter an XNA Game Studio setup failure.

How to work around this issue

If you run into this issue, here are steps that you can use to work around it:

  1. Download and install the latest version of the Games for Windows – LIVE Redistributable from http://www.xbox.com/en-US/LIVE/PC/DownloadClient
  2. If you are installing the Windows Phone SDK 7.1, re-run setup and choose to repair it.  This will re-run the previously failing XNA Game Studio installers and they should install correctly this time.
  3. If you are install a standalone XNA Game Studio product, re-run setup and it should install correctly this time.
  4. If you are planning to do Windows Phone development, you should also install the Windows Phone SDK 7.1.1 Update after installing the Windows Phone SDK 7.1.  This update fixes an issue that prevents the emulator in the Windows Phone SDK 7.1 from working correctly on Windows 8.

What to do if the workaround doesn’t help

If you have tried the above steps and setup still fails, you are running into a different issue than the one described above, and you will have to look at the setup log files to determine the root cause.

If you are installing the Windows Phone SDK 7.1, you can use the log collection tool to gather your setup log files. This log collection tool will create a file named %temp%\vslogs.cab.

If you are installing XNA Game Studio, you can find log files at the following locations:

  • XNA Game Studio 4.0 Refresh - %temp%\XNA Game Studio 4.0 Setup\Logs
  • XNA Game Studio 4.0 - %temp%\XNA Game Studio 4.0 Setup\Logs
  • XNA Game Studio 3.1 - %temp%\XNA Game Studio 3.1 Setup\Logs
  • XNA Game Studio 3.0 - %temp%\XNA Game Studio 3.0 Setup\Logs
  • XNA Game Studio 2.0 - %ProgramFiles%\Microsoft XNA\XNA Game Studio\v2.0\Setup\Logs

Once you have gathered your setup log files, please upload them to a file server of your choice (such as http://skydrive.live.com), and post a link to the log files in the App Hub Forums or in a comment on my blog to get additional support.

What is causing this failure behind the scenes

XNA Game Studio installs a version of the Games for Windows – LIVE Redistributable behind the scenes.  Some older versions of the Games for Windows – LIVE Redistributable attempt to install and use a file that is being installed by Windows 8, and the older versions of the redistributable are not compatible with the newer version of the file that is installed by Windows 8.  Newer versions of the Games for Windows – LIVE Redistributable are compatible with Windows 8, and if you pre-install the new redistributable before installing XNA Game Studio, setup will recognize that it is already there and use the new version instead of trying to install the old version.

The reason this issue also impacts the Windows Phone SDK 7.1 is that this SDK installs XNA Game Studio behind the scenes, which in turn installs the Games for Windows – LIVE Redistributable behind the scenes.

<update date="7/12/2012"> Added a note about installing the Windows Phone SDK 7.1.1 Update after installing the Windows Phone SDK 7.1 to fix an emulator issue on Windows 8. </update>

<update date="7/22/2012"> Fixed broken link to the Windows Phone SDK 7.1.1 Update </update>

<update date="10/30/2012"> Removed outdated reference to the Windows 8 consumer preview. This post applies equally to the final release of Windows 8. </update>


  • Hi Aaron, sorry for the slow reply

    I have installed the recent update and the problem percist.

    I have changed the compile output to Diagnostic but it still gives me only one error with no additional information.

    I created again a fresh empty default xna windows phone project.

    Also I'd like to point out it is uniquely with xna applications and not with silverlight.

    The update fixed the emulator also.

  • Hi K - I see the location where this error is coming from in the file C:\Program Files (x86)\MSBuild\Microsoft\XNA Game Studio\v4.0\Microsoft.Xna.GameStudio.XBL.targets, but I don't understand what would trigger this error.  I'm hoping there will be more information in the diagnostic build log about what some of the variables used by that file are being set to on your machine, so if possible, can you please zip your diagnostic MSBuild log file, upload it to a file server (such as http://skydrive.live.com), then reply back here and post a link that I can use to download your log file and take a closer look?

  • Hi, sorry, I could't even find the build log file.

    I copy pasted the error and warning to a text file (buildlog.zip) and the whole project folder (as created by my env).


  • Hi K - Unfortunately, the files that you uploaded don't give any more information than you already provided, and the project you uploaded works fine when I try to build it on my computers.  After you enable diagnostic MSBuild logging, you'll need to build your project again, let it fail, then copy and paste the contents of the VS output window into a text file.  Can you give that a try and upload it to your file server?

  • I think the build doesn't even happen because of this error. The build folder is empty. Build, rebuild clean etc doesn't really do anything

  • Hi K - Right, I'm expecting your builds to continue to fail.  However, if you have diagnostic MSBuild logging enabled, you'll get a bunch of information printed to your output window in Visual Studio when your build fails.  That is the information I'd like you to copy and paste into a text file and upload so I can take a look.

  • Sorry my bad.. here it is. Thanks a lot for your patience!


  • Hi K - Thank you for the additional log file.  XNA Game Studio ships a file named Microsoft.Xna.GameStudio.XBL.targets that includes the following logic:


    In your log, the SPAFileMarker variable is being evaluated as ?1, when it should really be evaluated as -1 (to indicate that the index isn't found).  I'm not sure what would cause the IndexOf method to return a non-numerical value like that though.  Maybe there is some culture setting for your OS that is causing this?  What language version of Windows are you using, and what culture settings is your version of Windows configured to use?

    This logic for parsing SPA files is only needed by games that are a part of the registered Xbox LIVE developer program.  If you're not a part of that program, I think you can work around this issue in the meantime by deleting the following error from your copy of Microsoft.Xna.GameStudio.XBL.targets:

       <!-- Limit to a single SPA file -->

       <Error Condition="'$(SPAFileMarker)' > '-1'"

              Text="Multiple SPA files are not supported."/>

  • Yep, thanks very much, that fixed it.

    I had location finland and number and format as Finland.

    Changed those to US and the error is gone.

    :D High five!

  • This worked for me on VS2010 Ultimate and Win8 (8250)


  • sir u need help......how i install xna 4.0 on vs2011......

  • Hi Ahsan - XNA Game Studio 4.0 only supports Visual Studio 2010.  You can install VS 2010 side by side with VS 11 if you would like to develop games with XNA Game Studio and also use VS 11 on the same computer.

  • After install LIVE Redistributable, wp7 and xna sdk were successfully installed. But, then I try to create a new project "Game For WindowsPhone", vs show me error: Object reference not set to an instance of an object. If I press "OK", it is created solution with content projerct only. Also, my old projects, don't open too.

    Sorry, for my bad English.

  • Hi Sarostin - Does this error only happen for XNA Game Studio games for Windows Phone, or does it also happen for Windows and/or Xbox 360 games?  If it is only phone games, then I'd suggest trying to repair the Windows Phone SDK 7.1.  If it is all types of XNA Game Studio games, then I'd suggest trying to uninstall and re-install XNA Game Studio.

  • I was having the same issue, and the post really helped, thank you!

Page 2 of 9 (131 items) 12345»
Leave a Comment
  • Please add 5 and 6 and type the answer here:
  • Post