Visual Studio 2015 does not install Android SDK tools for Api 19,21,23 etc for Xamarin - xamarin

I am moving towards Xamarin for cross-platform application development. I already had VS2015 installed, I downloaded Xamarin tools(vstoolsforxamarin.exe) from their website and when I install them after a long wait VS says "setup completed with errors"and it does not download and install Android SDK for API 19,20,23, It always say:"Please check your internet connection and try again" and i am sure that my internet connection doesn't get disturbed during all this process. I have tried this 3 times now, tried by uninstalling VS2015, installing it again but got the same error. What is the problem that is causing this? I already have Android Studio installed, with its SDK manager. Any help would be appreciated, that to get Xamarin running in VS2015.
EDIT:
Solution:
I already had Android Studio and its SDK on my system, going to Tools>Options>Xamarin from Visual Studio and giving path of the Android SDK solved my problem. Read this answer on StackOverflow somewhere!

Seems like this issue is caused because Visual Studio is trying to download thrid-party libraries (Android SDK). You can fix this from Control-Panel
Have a look at this post.

Make sure you have installed Java JDK, I had similar issue reported here
Visual Studio 2015 Enterprise Reports Internet Connectivity Issue while there is no issues with networking

As mwilson64 answered in response to Android SDK Setup API not installed (same as linked above on "Have a look at this post."), my steps to resolve:
Create file %USERPROFILE%.android\androidtool.cfg
Paste the following into new file (created in step 1):
# Settings for Android Tool
# Last updated: Wed May 19 17:09:27 UTC 2017
http.proxyPort=8888
sdkman.enable.previews=false
http.proxyHost=127.0.0.1
sdkman.ask.adb.restart=false
sdkman.show.update.only=true
sdkman.force.http=false
sdkman.use.dl.cache=true
Replace values in proxyPort and proxyHost with your company's proxy settings.

Related

Could not find SDK "WindowsMobile, Version=10.0.18362.0" error in VS17 when deploying to HoloLens

I'm new to HoloLens (and Microsoft's ecosystem) and am following this tutorial to learn. One of the steps is to deploy from Visual Studios to HoloLens, but when I try to I get this run-time error.
I have confirmed that I have followed this guide from Microsoft to set up my development environment, but my error still persists.
In Unity, these are by build settings and Player settings as instructed in the tutorial:
My Windows 10 computer is running on 1903, my HoloLens is on 1804, and I have both Windows SDK 10.0.17x and 10.0.18x installed on my computer (via Visual Studios installer and this link). I have also tested deploying the app using the 10.0.17x SDK, but end with the same results.
I can simulate my app from Unity using the Holographic Remoting app in HoloLens, but I just can't deploy it from Visual Studios. What is causing this error and how can I solve it?
Update:
I have tried re-installing the Windows 10 SDK (both 10.0.17x and 10.0.18x), but this did not resolve the problem. My Windows 10 SDK is installed in my D: drive if that would make any difference.
Update 2:
I read somewhere that if you simply delete those files from the project tree in Visual Studios, the error will go away. Indeed it did and I could build and run just fine after that seemly without issue, but there must be something wrong with deleting SDK files like that... Is deleting them safe?
Thank you for your help!
I managed to get this to work by deleting the reference to the Mobile SDK in the vxcproj file. It doesn't seem to be required!
App deployed to Hololens successfully!
According to the error message from the picture you post, there seems to be a problem with your Windows 10 sdk. Please check if the files in this directory are damaged (C:\Program Files (x86)\Windows Kits\10\Extension SDKs\WindowsMobile\10.0.18362.0), and try to reinstall the Windows10 SDK:https://developer.microsoft.com/en-us/windows/downloads/windows-10-sdk

Taco roadmap - Update 11 with Cordova 7 support

Are there any plans by Microsoft to release a Taco Update 11 with native Cordova 7, Node 4.x support?
Is Taco still an active project since the last update was two years ago?
I think it is safe to assume Microsoft has abandoned TACO platform, putting their focus in this space to Xamarin.
As you pointed out, the last update to the tool was 2 years ago, Jan 2016.
The last entry in The Visual Studio Blog ("The official source of product insight from the Visual Studio Engineering Team") was 15 months ago, Oct 2016.
According to his LinkedIn profile, Jordan Matthiesen, who was Program Manager for VS Taco, is now Program Manager for Visual Studio For Mac.
For myself, a Visual Studio user for 27 years, I have switched to using Cordova CLI and Visual Studio Code on Mac.
After a few try i have found a way:
Follow this steps:
install nodejs 4.8.7 on your machine
in visual studio go under tools>options>"Tools for apache cordova"
and deflag chekbox "use a sandboxed version of NodeJS"
Edit taco.json file of your project and set "cordova-cli": "7.1.0"
Open a new console and install cordova on your machine (npm install
-g cordova#7.1.0)
For android build:
open prompt, digit android and press return
dovnload API 26 SDK from tool
download gradle 2.x and put bin folder in your system path
install jdk 1.8.x and set java_home system var to it
reboot
For those that still use TACO for visual studio, I found the following instructions to update Visual Studio Tools for Apache Cordova for VS 2017 to use Cordova #7.1.0 and Cordova-Android #6.3.0
https://github.com/brunolau/vs-taco-update
It tells you how to find the old toolset (6.3.1) and how to replace it with a new version, and also how to update android to API level 26.
It also shows you how to create your own custom toolset, which I haven't tried, but sounds very useful.

Visual Studio: Android SDK Setup (API Level 19 and 21,22,23)

I have this problem with the setup of Android SDK in Virtual Studio Community 2015. Whenever I try to install or repair VS, I always get problems with the setup of API Level 19 and 21,21 and 23. It always says that the packages were not downloaded and I should check my internet connection. However, my internet connection is working perfectly. I have seen many other users having similar problems, but none of the proposed fixes work for me. I have reinstalled VS twice and repaired it like 3 or 4 times. I checked my Java version and my proxy settings or tried installing them via the Android SDK Manager/alongside Android Studio. So far without any luck. I hope I have not overseen any fixes.
Unfortunately, the log is very long, so I can´t post it here (if you have any suggestions where I can post it, please tell me!). In the links you will find two screenshots of the error message I get.
Can you help me?
All I did was install Java SE Development Kit 8u151 from Oracle (Apparently VS 2015 uses Java 7 instead of 8) and then run VS 2015 as administrator and modify. The third party SDK's (19, 21, 23 & 22) were available and all installed correctly. Wish I had of known this before multiple installs and eventually a reinstall of my OS ...suppose I could have done with a clean slate though.
I was able to solved the problem above using the suggestion and comment of #Richard_Norton and #bugzapper from, https://social.msdn.microsoft.com/Forums/sqlserver/en-US/780c0b11-41da-4935-9ae5-dadf38292b51/android-sdk-setup-api-not-installed?forum=vssetup .
I uninstall the older version of Java SE Development Kit which is not Version 8.
I download and install the Java SE Development Kit Version 8 which you can get in here http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html .
Then after that i modify Visual Studio 2015 to Install Android SDK Setup (API Level 19 and 21), and 23.
I Hope, this answer can help future someone who is encountering this kind of problem.
Refer to the error message, you can have a try with the following methods:
Open Android SDK Manager and click Tools-Options… and check the option “Force https://... Sources to be fetched using https://...” and try to download those android SDK packages again. If you already tried this before, you can ignore it.
Check this blog: Visual Studio 2015 install failures (Android SDK Setup) behind a Proxy and follow the steps as below to fix it:
• BEFORE installing Visual Studio, create a file at this location: %USERPROFILE%.android\androidtool.cfg
• In the androidtool.cfg file that you just created, place those contents that you can find from the blog. Make sure to update “http.proxyPort” and “http.proxyHost” in the file!
• Install Visual Studio normally
Have a look at this similar issue: Visual Studio 2015 setup issue with Android SDK – hack it!, if you found the same root cause: all google repositories don’t have this package anymore on your side, you can try to create your own repository contains this missing package and let Visual Studio setup “think” he download the package and unzip it successfully.
BTW, the installation log file can upload to https://onedrive.live.com/ and share the link here.
Just start the SDK Manager from Visual Studio's menu (Tools/Android/Android SDK Manager...) and select the desired API level you do want and download them!
Anyhow, check with the SDK Manager, this is THE tool to get the Android SDK and at times you will need to update stuff through it!

Visual Studio Cordova App, can't run debugger - Could not locate the appxrecipe file

If I create a brand new Cordova project (JavaScript or TypeScript) and try to debug on Ripple or on the local machine I get an error during build that says "Could not locate the appxrecipe file."
I googled it and nothing comes up. What is this file and how does it get generated? Shouldn't it be generated when I create the project?
I've already lost an entire day to this, running repairs on visual studio and trying things that had no effect. Frustrating!
This took a while to figure out but it seems that the version of node.js that would get installed with Visual Studio was too old (0.10.x). When I installed the x64 version of node.js from the node website, it installed a 64 bit version which also wouldn't work with Cordova in Visual Studio.
The answer was to install the 32bit version of node.js (node-v5.1.0-x86.msi) available from their website. Now everything compiles correctly!
I was also stucked with the issue but my problem was little bit different. I wanted to build a project for Windows 10 Mobile platform.
It was really weird because everytime when I tried to build a project from CLI with ionic build windows, the build was successul. But it had been throwing the error about appxrecipe file while building with Visual Studio again and again.
Then I noticed that everytime I open a project in Visual Studio (2015, Community Edition) there is one change when you open your confix.xml file in Visual Studio editor - the change was that Windows Target Version was set to 8.1 again. I tried to change it to Windows 10 again, save it and build but the error was still there.
I have solved it with installation of Microsoft Emulator for Windows 10 Mobile and it works like a charm now. Maybe this information could be helpful for somebody...

How to install Xamarin.Android for Visual Studio Enterprise 2015 offline

I want to install Xamarin for Android Development in Visual Studio 2015 Enterprise.
While installing, Xamarin told me that I was missing a lot of features, so it would download and install them for me. The download size was around 2GB, and I have a really slow internet.
I wanted to know if there is a way to download Xamarin and all required components separately, using some download manager like IDM, and then be able to use it later to re-install/install on another PC.
Also, I was able to find offline setups for JRE and JDK, and also Android Studio and Android SDK/NDK, but still, the download size is around 1.5GB, which I presume is for the required Android SDK libraries, APIs and tools.
So, I am just asking for a guide on downloading all the components and store them for installing later.
According to the official docs (whose pictures are outdated, by the way) you should login to your account and then head to the download page where you could find links to different versions of Xamarin.
I did so, but all that's available there are older versions of Xamarin Studio and the universal installer. Similar searches on the Xamarin Forums yielded no results as well.
There's a way to find the direct URL for each installer by checking the XML used by the Platform Installer (located at \AppData\Local\Temp\Xamarin\downloads\InstallationManifest.xml). I haven't tested whether installing them separately will work or not, but it probably will. Just make sure to install them in the right order (and to install the Android SDK/NDK after installing Xamarin.Android)
Here are the links to the latest versions, as of today:
Xamarin.Android
Android SDK
Android NDK (x64)
GTK#
Xamarin Studio
Xamarin for Visual Studio
It'd be good if someone with a Mac could help me find the URL for Xamarin.iOS, but that's a start :P
You can download this XML file and find the link of latest version of all required components.I did this and the latest links are :
Java JDK 1.7
Android SDK 24.4.1
NDK 10 (32) or NDK 10 (64)
Xamarin for Visual Studio 2015 4.1.2.18
Intel HAXM 6.0.1
Microsoft MSBuild Tools 2015.0
You don't even need to login for download them.
After 1st web install, backup %tmp%\Xamarin\downloads\ , then on a new Windows:
Uninstall Java 1.8 if exists.
Manually install Java JDK 1.7u71 + GTK# + Android SDK (Install for anyone).
Extract NDK to "C:\Program Files (x86)\Android\android-ndk-r10e", or make NTFS junction to it (not to run out of C: space later).
Run XamarinInstaller having just *.zip files in %tmp%\Xamarin\downloads\, when you see that current download is "XamarinStudio", disconnect Internet (you can delete the NDK now).
When you see above the progress bar: "Downloading Xamarin Studio", you can close the web installer.
Manually install Xamarin.VisualStudio, and if you want, XamarinStudio.
Step 4 require Internet, but noting to download.
To make NTFS junction, from "C:\Program Files (x86)\Android" prompt:
mklink /j android-ndk-r10e T:\android-ndk-r10e
where T: can be USB drive, but not Network drive.
I know it's a link only answer (copyright!), but there are step-by-step instructions including screenshots of how to do that:
Installing Xamarin Made Easy with Offline Installation
I've not tried it, but it should help you.
Found this:
http://ionemind.com/content/get-direct-download-links-xamarin
Links to XML files with direct links to necessary components for Xamarin, including Xamarin for Visual Studio (version 4.5, for VS 2013 and 2015).
Another link I found:
https://dl.xamarin.com/XamarinforVisualStudio/Windows/Xamarin.VisualStudio_4.8.0.1289738.msi
I had installed Xamarin Studio 5 and then it autoupdated its components (to Xamarin Studio 6.3 and the mentioned VisualStudio Tools 4.8).
Then in the "AppData/Roaming/Xamarin X.X" I found a folder for temp downloads. There was the MSI file.
Then I just searched for this exact MSI name to get a direct link.
(on this site https://itblogdsi.blog.fc2.com/blog-entry-23.html)
There's actually some info about releases and MSI names and it has Xamarin.VisualStudio_4.9.0.1538920.msi so replace this part in the MSI link above.
It's for VS 2015 only.

Resources