2

I have met this trouble in both VS2013Up4 and VS2015Pre. My OS is Win8.1 Pro x64. The detail message about the error:

Cannot find module 'q' MDAVSCLI 1 1 WinJSToDo.

And I can get nothing from double click it. Please help me. ORZ... Currently I'm using Visual Studio 2013 update 4 with Visual Studio Tools for Apache Cordova extension on Windows 8.1. I create a new Cordova JavaScript Blank project and then trigger a build, it turns out to be below building error:

Error 2 Cannot find module 'q' C:\Users\penlv\documents\visual studio 2013\Projects\BlankCordovaApp1\BlankCordovaApp1\MDAVSCLI 1 1 BlankCordovaApp1

Seems many other users run into the same issue. Any help on this?

devrys
  • 1,571
  • 3
  • 27
  • 43
ToHiD T
  • 29
  • 1
  • 3

2 Answers2

1

You can try this link if works. And also this.

I tried but still have the same error.

Finally i have 'Cannot find module' error fixed:

  1. copy 'lib' and 'resource' folder from 'C:\Program Files\nodejs\node_modules\vs-mda' to 'C:\Users\[user-name]\AppData\Roaming\npm\node_modules\vs-mda'

  2. in 'C:\Users\[user-name]\AppData\Roaming\npm\node_modules\vs-mda' folder, run npm install command

Community
  • 1
  • 1
21paradox
  • 31
  • 1
  • 3
0

I had this issue when my "User Account Control" was switched on (Windows 8.1).

The solution was to run Visual Studio as Administrator, and then clear your cordova cache, and rebuild.

Louis van Tonder
  • 3,664
  • 3
  • 31
  • 62