title: Clickonce application runs the first time but throws an exception the second time
body: <p>I have a .NET 4.0 application. On the first run, the installer runs, and the app opens normally. If you run it when it's already installed, it throws this exception: </p>
  
  <pre><code>System.BadImageFormatException was unhandled
  Message: Could not load file or assembly '[my assembly]' or one of its dependencies. 
  This assembly is built by a runtime newer than the currently loaded runtime and cannot be loaded.
  </code></pre>
  
  <p>The app was previously .NET 3.5, and I changed the main project and two dependencies to .NET 4. There are other references using .NET 2 and .NET 3.5, but none higher than 4. Any idea what's going on here?</p>