3

When I attempt to create a new blank Cordova app in Visual Studio 2013 with the Multi Device Hybrid Apps CTP I get the following error message.

Has anybody else experienced this? I was thinking that it could be a Node/NPM issue but they both work correctly on my machine (before and after the install).


Edit: I should have mentioned that I already tried the answer found here: Cordova Multi-Device Hybrid Apps (Preview) for Visual Studio | Can't load project.

VLAZ
  • 26,331
  • 9
  • 49
  • 67
Levi Botelho
  • 24,626
  • 5
  • 61
  • 96
  • Looks this was answered here as well: http://stackoverflow.com/questions/24212443/multi-device-hybrid-apps-preview-for-visual-studio-cant-load-project – Burcu K Jul 07 '14 at 20:21
  • Sorry, I should have mentioned that I already tried that. – Levi Botelho Jul 07 '14 at 20:35
  • Could you explain what you mean by "I was thinking that it could be a Node/NPM issue but they both work correctly on my machine (before and after the install)." – Priyank Jul 08 '14 at 18:54
  • Because the error involves a node modules folder, the thought had crossed my mind that my Node installation could be part of the problem. However Node works and always has worked on my computer so I doubt that a good installation could be the cause of this. The fact that the product is in CTP is much more likely. – Levi Botelho Jul 08 '14 at 19:13
  • I work on the MDHA feature for Visual Studio and will inform the team about this issue - as you say that Priyank's advice didn't work, I can only suggest uninstalling and re-installing MDHA. Did you install the 1.1 release that shipped shortly after the original CTP? – Dai Jul 09 '14 at 09:10
  • @Dai - I tried repairing the installation and that didn't help matters. I uninstalled the CTP yesterday (took a **very** long time) but haven't gotten around to reinstalling it quite yet. I can confirm that I am using the 1.1 release. – Levi Botelho Jul 10 '14 at 06:25
  • @LeviBotelho Any news on this? I'm having the exact same error just trying to open the blank project. I'm using VS 2013 update 3 and the CTP2.0 release and see the exact same error. Not sure if it matters, but node was already installed before installing CTP2.0. Node v0.10.26. I've tried a complete reinstall of MDHA with no success, and yes it takes forever to uninstall. – Jason Eades Aug 22 '14 at 18:33
  • Still no news @JasonEades. I ended up switching to Ubuntu and Atom to do my dev while I wait for this issue to eventually be resolved... – Levi Botelho Aug 22 '14 at 20:17
  • 1
    @Dai I've got the same problem with community edition. Now I've found that the [two main pre-requirements](https://i-msdn.sec.s-msft.com/dynimg/IC741960.png) for MDA3.1 is not available in community edition of VS2013 – IsmailS Apr 25 '15 at 17:25
  • Could you solve it? Please add an answer if you could. Thanks! :) – Leandro Bardelli Apr 30 '15 at 23:47
  • I solved it by developing PhoneGap on Ubuntu with Atom ;). – Levi Botelho May 01 '15 at 05:26

2 Answers2

1

MDHA projects require that Node be installed on your machine to be able to create a project. While you mention that NodeJS is installed, there's a possibility it may be stale or corrupted.

Try these steps:

  • Close VS
  • Uninstall NodeJS
  • Reboot machine
  • Install NodeJS from nodejs.org
  • Start VS and try to create a project

This should resolve your issue.

Priyank
  • 1,568
  • 10
  • 15
1

I had the same exact error as Levi and it was because a few directories were not created in the node_modules directory during installation. Re-installing node and/or the entire CTP2.0, restarting, clapping my hands, screaming, etc would not fix this in my environment. On another PC, this worked fine. To fix this problem:

  1. Navigate to C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\IDE\Extensions\ and search for "vs-mda". You should find both a "vs-mda" and "vs-mda-targets" folder. (Make a recursively search, you won't find the folders exactly in "Extensions", there are inside of a random-named folder)
  2. Copy those two folders to the location the error is complaining about%appdata%\npm\node_modules\
  3. Restart Visual Studio and the error should go away

Now, once this worked, I still got an error about the Git CLI missing. That was solved with this answer.

I hope this helps!

Community
  • 1
  • 1
Jason Eades
  • 1,547
  • 5
  • 16
  • 31