20

I have a project that was working on RC and worked with no problems. Updated to RTM and now I cannot start the application

I also created a new black cordova app and still can't start the application.

Looked everywhere and found no reference to this problems. Others suggest that environment variables are not set or tools not installed. I triple checked and environment variables are fine and tools are indeed installed.

I uninstalled everything (including git) from programs and features and reinstalled vs2015 RTM with no success, same problem.

I also installed extra stuff from android sdk manager, no luck.

No idea what's wrong and the error message visual studio gives no clue.

Enviroment paths error message empty dropdown android sdk manager

Bart Calixto
  • 19,210
  • 11
  • 78
  • 114
  • What do you have in your build output? I can't build a fresh Cordova project at the moment after upgrading to RTM – Klors Jul 21 '15 at 14:00
  • I have upgrade to RTM and I can only Debug > Android > Ripple -. Debug > Android and Windows device are not working. – DeanB_Develop Jul 21 '15 at 14:50
  • Removed VS 2015 RC and installed VS 2015 RTM. Can't build Cordova project. – SPDoctor Jul 21 '15 at 16:11
  • @SPDoctor check the build setting out that I posted in my answer, it should help you to get a better idea of what's failing – Klors Jul 21 '15 at 17:06
  • 1
    build success. no error. If I do npm install ripple-emulator and run ripple emulate from command prompt, it works. I did clear cache and reinstall vs-tac and also re uninstalled / installed cordova tools, sdk, etc. it's just like vs doesn't pick up the debugger. I also run a full repair. Still no luck. – Bart Calixto Jul 21 '15 at 20:52
  • Already have build set to diagnostic output. Nothing. See related question here: http://stackoverflow.com/questions/31543473/vs2015-rc-to-rtm-cordova-project-nuked – SPDoctor Jul 22 '15 at 09:45
  • @Bart or anyone else with this issue, in the original step, did you uninstall RC before installing RTM or was it an upgrade of RTM on top of an existing RC on the box? Also, did you have previous Developer Preview (DP) builds on the box? – Leo Jul 27 '15 at 22:47
  • I had previous Developer Preview and I uninstalled RC before installed RTM. @Leo – Bart Calixto Jul 31 '15 at 18:07
  • RC was uninstalled before install RTM. Ended up doing a re-pave. Was probably node.js that failed to upgrade properly. – SPDoctor Aug 13 '15 at 10:49

11 Answers11

34

Looks like a library is corrupted from the upgrade. Please give this a try:

  1. Close all VS instances
  2. cd %appdata%\"..\Local\Microsoft\Phone Tools"
  3. rename CoreCon folder to something else
  4. Launch VS again.

That's it.

gReX
  • 1,060
  • 1
  • 20
  • 35
Leo
  • 526
  • 3
  • 5
  • and you telling me this now few hours before format and install win10 ? really. I hate you, but yes. It worked like a charm. I hope you are from microsoft because there's no way someone can figure this out by itself :D. Btw, the correct command is: `cd %appdata%\"..\Local\Microsoft\Phone Tools”` – Bart Calixto Jul 28 '15 at 22:19
  • 2
    Rename "CoreCon" to anything other than "CoreCon" ;) – Leo Jul 29 '15 at 05:00
  • Leo still missing the " on path. Just copy paste :) – Bart Calixto Jul 29 '15 at 06:07
  • Bless you! I was about to try recreating my project. – Doug Weems Jan 22 '16 at 03:07
  • Thanks so much! I was getting a similar error (not exactly the same, but perhaps it's changed slightly since you posted this). Either way, your solution works beautifully. – Sam Jan 04 '17 at 04:59
2

The answer from Leo works for me.

Here the documentation of my research, if it does not work for any other user.

Watch the output, to get your specific cause. Increase the build-Verbosity in VS-Options.

go to Tools -> Options -> Tools for Apache Cordova, click the 'Run Dependency Checker'.

Check the installed Visual Studio features, this is selected by default:

VS for Cordova-Development

Compared to msdn:Install Tools for Cordova

Add also:

  • Emulator for Windows Phone 8.1
  • Android Native Development Kit (R10E, 32 bits)

And if you still get no emulator after compiling a blank cordova app:

no preinstalled 8.1. Emulator

I think then you have to install google chrome: msdn "The installer does not install Google Chrome, which is required if you want to run the Apache Ripple simulator for iOS and Android, and it does not install Apple iTunes, which is required for deploying an app to an iOS device connected to your Windows PC."

Also check your Hyper-V Settings:

I'm checking out the Tools\Visual Studio Emulator for Android: Activated Emulator Message

Check the SystemRequirements

Check this link: Troubleshooting the Visual Studio Emulator for Android

Or give "reinstalling node.js" a chance. Wait for "Setup Repair" again.

Hope my documentation here helps someone.

gReX
  • 1,060
  • 1
  • 20
  • 35
2

I had the same issue using Ripple Emulator. I solved the problem by deleting the cache of cordova (VS-Tools-Options-Apache Cordova Tools-Cordova Tools-Delete cache...).

I've also changed the port from 4400 to dynamic (under Ripple emulator).

1

I know this isn't an answer (yet). I submitted this issue with Microsoft (I'm experiencing the same thing). I figured I would see what they say. I'll keep you posted if there is any progress.

https://connect.microsoft.com/VisualStudio/feedback/details/1573191/visual-studio-2015-typescript-cordova-project-is-giving-the-error-the-debugger-cannot-continue-running-the-process-unable-to-start-debugging-when-trying-to-run-debug

Phobis
  • 7,524
  • 10
  • 47
  • 76
1

I had the same issue and I finally fixed it. I think the issue is with the node upgrade. First.. uninstall node.. and I mean get everything.. after you uninstall make sure you delete node from the program files and your user folder.. In the user folder make sure to get both the npm folder and the npm-cache. Then installed node from the latest installer on the web site.. Oh yea.. make sure you get the 32 bit version.. just had issues with the 64 bit.

Then I did a repair on Visual Studio 2015... Rebooted and it all worked again..

Jon Z
  • 516
  • 6
  • 14
  • I really wanted to accept this answer. Unfortunately, I uninstalled node, completelly, installed the 32 bit version, restarted, repair vs, restarted again. open project, rebuild (this installs vs-tac), go to cordova tools, check dependencies, nothing missing. and yet, I cannot get to visual studio pick up the debugging options. :( I will reinstall windows next week, dont' want to do it now. for the time being, I installed npm install ripple-emulator and im testing it using ripple emulate. but it sucks. – Bart Calixto Jul 23 '15 at 17:32
0

My first port of call would be to check your build output after setting your build output logging to Diagnostic.

VS Menu > Tools > Options > Projects and Solutions > Build and Run > MSBuild project build output verbosity > Select - Diagnostic

This might then give you a clearer indication of why it is not building/debugging.


This led me to a couple of issues, though yours may not be the same.

npm GET failing behind proxy due to Tunnel Agent

The main issue for me being that (I presume) the install had changed the version of nodejs on my machine. There was a node error when trying to get dependencies from npm to do with the Tunnel-agent Request path contains unescaped characters.

Googling around led me to an Ionic issue - https://github.com/driftyco/ionic-cli/issues/321 - and following the advice for changing the index.js file in the Tunnel Agent folder fixed the issue for a new Typescript Cordova project that I created to test. So then I just moved all my files to the new project.

Cannot find the right module

Another debugging step I tried along the way was to do with an error about not being able to find the right module (mentioned here - Configure the Visual Studio Tools for Apache Cordova).

If you see unexpected errors when trying to build the Blank App template, see Re-install vs-tac.

This tells you to Clear Solution, then Clear Cordova Cache (steps in the link), which is what lead me to re-GET the dependencies and find the NPM issue.

Community
  • 1
  • 1
Klors
  • 2,665
  • 2
  • 25
  • 42
  • build works ok. also, if I do npm install ripple-emulator and from command prompt I do ripple emulate it works with no errors/problems. It's just the connection of visual studio debugger not configured correctly with the jproj or something like that. – Bart Calixto Jul 21 '15 at 20:51
  • @Bart ah, I'll leave the answer in case it helps others, sorry it didn't help you – Klors Jul 22 '15 at 10:49
0

I suspect there was a problem upgrading from RC to RTM on the same machine. You might have to fix the issue by doing a fresh install of RTM on a clean box. Can you give that a try?

Michael Braude
  • 6,913
  • 1
  • 22
  • 20
  • I think that's what we are all afraid of :-( – SPDoctor Jul 21 '15 at 17:32
  • Based on some testing we did internally, I think the issue can probably be fixed by doing a repair on VS 2015. If anybody can give that a try and let me know if it works, that would be great. – Michael Braude Jul 26 '15 at 22:51
0

I have the same issue, cannot start a JS/TS cordova project.

I went to Tools -> Options -> Tools for Apache Cordova, click the 'Run Dependency Checker'. VS 2015 gave me a report as following:

=====================

Please fix the following issues to ensure that your app builds and runs successfully.

Software/Tool

Issue

Android Package: build-tools-19.1.0 One or more required packages are missing. Please update the packages as described. Instructions Android Package: sys-img-armeabi-v7a-android-19 One or more required packages are missing. Please update the packages as described. Instructions Android Package: sys-img-x86-android-19 One or more required packages are missing. Please update the packages as described. Instructions Android Package: addon-google_apis_x86-google-19 One or more required packages are missing. Please update the packages as described. Instructions Android Package: addon-google_apis-google-19 One or more required packages are missing. Please update the packages as described. Instructions

After fixing these issues, please restart Visual Studio to ensure that changes have been applied.

==================

I also found these links may be helpful:

https://msdn.microsoft.com/en-us/library/dn757054(v=vs.140).aspx

https://msdn.microsoft.com/library/dn771551%20(v=vs.140).aspx

https://github.com/Microsoft/cordova-docs#known-issues

Update: I installed Andriod SDK API 19 21 22 using the SDK Manager, no luck.

rIPPER
  • 447
  • 4
  • 12
0

I'm working through a similar issue. It seems in my case that the failure is specific to my Windows user profile. When I created a new local user account, the new user doesn't experience the problem. Removing your Windows user profile is a potential work-around, if you don't mind the hassle.

Community
  • 1
  • 1
BillVo
  • 565
  • 1
  • 5
  • 20
0

I just close all visual studios that are opening (vs 2012, vs2013) and reopen vs2015. Ripple-Nexus, Device, google emulator... appear instead of "start" icon only.

enter image description here

Chinh Phan
  • 1,459
  • 19
  • 22
0

If, after upgrading Visual Studio, you see the error message, "The debugger cannot continue running the process. Unable to start debugging.", a library may have been corrupted. Try the following workaround. Close all VS instances, then go to %appdata%\username\Local\Microsoft\Phone Tools, and rename the CoreCon folder to another name such as CoreCon2. Then try restarting your app in VS.

Linda Z
  • 312
  • 1
  • 5