I'm trying out simple SP 2013 SharePoint hosted apps against an Office 365 2013 dev site. When I start debugging the apps install fine; when I stop debugging no retraction occurs, I'm having to manually remove the app from the site.
2 Answers
Make sure that in Visual Studio under "Project->xy Properties" under the "SharePoint" section the option "retract after debugging" is checked.
You need to retract or uninstall app, Simply stopping debugging won't going to retract or uninstall the app automatically.
If you tried to retract and uninstall app and got error then,
You need to change the ProductID in the appmanifest.xml file to something else. This will deploy another app with the same name.
I guess this is a known issue and at this time there doesn't appear to be any way to remove the old instance.
Remove app for SharePoint instances from a SharePoint 2013 site