“The application could not be started.” error when debugging a Windows 8 Metro Style App
I ran across this today and wanted to share the fix. I have seen it crop up both XAML/C# and HTML/JS projects and has to do more with how the app is registered.
The error appears when you attempt to debug your Windows 8 metro Style App you will be prompted with a dialog informing you the application could not be started.
Clicking on Yes for more information will show you the id of the Metro Style App and point you to the Debug->Windows->Output window. Unfortunately looking in the Output window doesn’t give you much information either.
The goods news is the fix is simple! Simply exit out of Visual Studio 11 Beta and navigate to the solution file of your project. Once there delete everything inside of the bin folder.
Then open the project back up in Visual Studio 11 Beta and it should deploy correctly for debugging!
-Dave
You may also want to check out my previous Windows 8 Metro Style Development Tips:
- Accessing the Accelerometer in a Windows 8 Metro Style App using HTML and JavaScript
- Accessing the Camera in a Windows 8 Metro Style App using HTML and JavaScript
- Using KnockoutJS in Windows 8 Metro Style Apps
- Illegal characters in path when deploying a Metro Style App
- Playing Music and Sound Effects in a Windows 8 Metro Style App using HTML and JavaScript
- Connecting to WCF RIA Services in a Windows 8 Metro Style App using Upshot.js and Knockout.js
- Help! Visual Studio 11 Beta Dark Theme incorrectly using White Background
- Adding Touch support to a Windows 8 Metro Style App using HTML and JavaScript
- Defining Layout in a Windows 8 Metro Style App using CSS3, HTML and JavaScript
- Handling Fullscreen, Snapped and Filled states in Windows 8 Metro Style apps using CSS3 and JavaScript