HTML5 Zone is brought to you in partnership with:

Robert is a South African technology specialist with focus on Microsoft technologies. He is very passionate about teaching and sharing and is a Microsoft MVP & Ranger. Robert is a DZone MVB and is not an employee of DZone and has posted 75 posts at DZone. You can read more from them at their website. View Full User Profile

Visual Studio 2012 - LightSwitch: The selected project was created by a newer version...

03.06.2013
| 1826 views |
  • submit to reddit

You may have run into this annoying dialog when creating an HTML application with Visual Studio 2012 LightSwitch after installing Update 2 CTP 4. The issue does not appear when creating a “normal” application.

The cause of this is a conflict between the old bits that came with the Office Dev tools update and the new bits that came in the Visual Studio update.

Prevent it in future!

You can prevent this by following these steps [source]:

Before installing CTP 4 you must uninstall HTML Client Preview 2 and clear the Application Manifest cache:

  1. Open Add\Remove Programs.
  2. Select the entry for Microsoft LightSwitch HTML Client Preview 2 for Visual Studio 2012.
  3. Right-click the entry and select Uninstall.
  4. Select the entry for Windows Azure Tools for LightSwitch HTML Client Preview 2 for Visual Studio 2012 – June 2012 SP1.
  5. Right-click the entry and select Uninstall.
  6. Clear your application manifest cache by deleting the following folders:
    • %localappdata%\Microsoft\MSBuild\VSLS\11.3
    • %localappdata%\Microsoft\VisualStudio\11.3
How do I fix it?

While the above is useful information ahead of time, it is is not helpful after the fact. So how do you fix your Visual Studio to be able to get into the fantastic new LightSwitch bits?

works-on-my-machine-starburstYour mileage may vary with this since this is been found with a bit of trial and error as I fixed on my machine.

First shutdown Visual Studio and then follow the steps above. Once done, run the CTP 4 installer again and chose the uninstall option. Once it is completely uninstalled you then reinstall the CTP.

Finally make sure you may want to make double sure you have cleaned the manifest cache (step 6 above) – it won’t hurt to do it again either. Just make sure Visual Studio is close when you do it.

Do not try a repair

You may think a repair is as good as an uninstall/reinstall of the CTP. It isn’t, since it gives you this lovely fun:

image

Published at DZone with permission of Robert Maclean, author and DZone MVB. (source)

(Note: Opinions expressed in this article and its replies are the opinions of their respective authors and not those of DZone, Inc.)