0
votes

Hello I am a new developer in ionic framework. When I build windows app, it shows some errors in command prompt:

E:\node\ionic\myApp>ionic build windows Running command: E:\node\node.exe E:\node\ionic\myApp\hooks\after_prepare\010_add_platform_class.js E:\node\ionic\myApp add to body class: platform-windows Building project: E:\node\ionic\myApp\platforms\windows\CordovaApp.Windows.jsproj Configuration : debug Platform : anycpu C:\Program Files\MSBuild\14.0\bin\Microsoft.Common.CurrentVersion.targets(2049,5): error MSB3774: Could not find SDK "Microsoft.WinJS.2.0, Version=1.0". [E:\node\ionic\myApp\platforms\windows\CordovaApp.Windows.jsproj] Error: C:\Program Files\MSBuild\14.0\bin\msbuild.exe: Command failed with exit code 1

enter image description here

Plese help me

2
ionic is only for android and ios there is no way we can build it for windows application. - Mohan Gopi
hey try to go through taco.visualstudio.com/en-us/docs/tutorial-ionic will get some idea at least.. hope it will help - Naitik

2 Answers

0
votes

https://issues.apache.org/jira/browse/CB-11204

The solution I used was to boot Visual Studio, select "File > New Project >Windows > Windows8 > Install Windows 8.1 and Windows Phone 8.0/8.1 Tools, to download the Windows platform and tools.

0
votes

Cordova can't find winjs.2.0, so you need to install it using NuGet. I did it from Visual Studio Code 2015. Just go to Project > NuGet Package Management, look for WinJS and install it. I Can't upload a couple of screenshots I took because imgur is failing :/ I hope this explanation be enough!