Published Install Fails: "Improperly Formatted"

Problem: Published project fails trying to install
Environment: VS2017 Community, version 15.5.4, .NET 4.7.02556, Monogame 3.6.0.1625
Details:

  • Created new empty Monogame project for Windows desktop
  • Builds fine, runs fine inside VS
  • Publish
  • Run the setup.exe — ERROR Dialog: “Cannot Continue. The application is improperly formatted. Contact the application vendor for assistance.”
  • Click on ‘Details’ button:
    ERROR DETAILS
    Following errors were detected during this operation.
  • [1/21/2018 6:57:57 PM] System.Deployment.Application.InvalidDeploymentException (ManifestParse)
    • Exception reading manifest from file:///C:/My/Code/FireAndIce/Application%20Files/FireAndIce_1_0_0_5/FireAndIce.exe.manifest: the manifest may not be valid or the file could not be opened.
    • Source: System.Deployment

Notes:

  1. I searched for similar topic and found a couple of same threads. None of them had an answer that worked for me.
  2. I turned off the ‘Security’ checkbox mentioned in another thread. Did not help.
  3. The manifest file DOES exist. I can open it in an editor and see all the xml just fine.
  4. I have tried this with 3 different projects – they all fail the same way, even on a new empty project that just brings up the blue screen.

4.5

MrValentine - Not sure what to make of your reply… all I see in my browser is a big gray “placeholder” picture (see screenshot below). As I am brand new to these forums, is there something I am missing? It appears the same in both Chrome and Edge.

1 Like

haha, ok, was in a hurry and you can’t post a short reply, did not notice you were new, Welcome to the forums :slight_smile:

4.5, set your .NET to 4.5 not 4.7