I recently installed android sdk v10 (API 29) in order to set the target framework in my application to v10. But I still can't find it in my application property.
enter image description here
I tried to reload the project but it did not work.
Help?
What's your visual studio version ? Is your Xamarin installation up to date? I suspect that your version of Xamarin.Android is 7.x which means that you won't be able to target Android 8.0 or above even if they are installed through the SDK manager.
You can check the version from Help > About Microsoft Visual Studio
Related
I have the problem that I'm not able to see the list of iOS simulators in Visual Studio Debug Target on my Windows PC
I've just made a total upgrade of my Xamarin development environment including now latest VS 2022, latest OS on my Mac, latest XCode version 14 and latest version of Xamarin on my PC and Mac. I have successfully paired to my Mac from Visual Studio.
On my Mac I've just tried to refresh the list of Debug devices as described in Microsoft Docs:
Delete your ~/Library/Developer/CoreSimulator/Devices folder.
Run killall -9 com.apple.CoreSimulator.CoreSimulatorService.
Run xcrun simctl list devices.
.. but still no result. All I can select in my Debug Target is Local Device, Remote Device and Simulator.
Before this upgrade I had no problem seeing all the simulators.
I will really appreciate if anybody have some good ideas of what I can do to solve this.
Following is my list of installed components from VS About box:
Xamarin 17.3.0.296 (d17-3#a0ff24b)
Visual Studio extension to enable development for Xamarin.iOS and Xamarin.Android.
Xamarin Designer 17.3.0.208 (remotes/origin/d17-3#e4f67afef)
Visual Studio extension to enable Xamarin Designer tools in Visual Studio.
Xamarin Templates 17.2.28 (9b3d244)
Templates for building iOS, Android, and Windows apps with Xamarin and Xamarin.Forms.
Xamarin.iOS and Xamarin.Mac SDK 15.12.0.2 (87f98a75e)
Xamarin.iOS and Xamarin.Mac Reference Assemblies and MSBuild support
Please be noted that XCode 14 is not yet supported in Xamarin.iOS or .NET MAUI, you need downgrade your Xcode version to 13.4.1 and could download it from the downloads page in the Apple Developer Portal. For more information, you can refer to https://github.com/xamarin/xamarin-macios/issues/15954
Update:
Xcode 14 is currently supported and if there are any other issues, please continue to post back to the GitHub.Thanks!
I have this same issue even after installing VS 17.3.6. I have no list of iOS simulators and I get a warning that this version of Xcode is not supported.
I have VS2017 and VS2019 installed side by side on my Windows 10 machine.
I can not compile Xamarin Android 4.1 projects (in VS2019) unless I upgrade them to 4.4 which seems to be the minimum Android SDK version I can target in VS2019. VS2017 compiles fine.
If I create a new Xamarin Android project in VS2019 I can select from 4.4 and above, but in VS2017 I can target right back to 2.3.
Both Visual Studio Xamarin settings are pointing to the same location for the android-sdk (which is on my D: drive, but I did copy it to the standard install location to verify it was not using this as a default, which made no difference)
VS2019 Minimum Android Version
VS2017 Minimum Android Version
Is it possible to target Android 4.1 using VS2019?
Use the following when making decisions with your Android versions:
minSdkVersion (lowest possible) <=
targetSdkVersion == compileSdkVersion/TargetFrameworkVersion (latest SDK)
It's also worthwhile to consider the Android Dashboard to understand how many devices are running a specific version of Android.
https://developer.android.com/about/dashboards
Selecting a higher "Compile using Android version" still lets the project compile.
Under the Android Manifest tab, you can still select the older Minimum and Target Android version allowing VS2019 to be used with this solution/project that uses an older Target Version.
Per the tooltip, Target Framework is only used at runtime.
I'm trying to run an already functional application that requires the Windows 8.1 SDK.
I installed Visual Studio 2019, but there is no option in the 8.1 SDK.
This is for a Windows 10 using Visual Studio 2019 last update.
On my old computer, there was the option to select in "Individual Components", but now no longer the encounter. Does anyone know if there is no such support on VS2019? Or is it necessary to install something more for the support to appear?
This is expected as it is marked as deprecated in Visual Studio 2019:
The Windows 8.1 SDK is no longer available in the Visual Studio
installer. Please upgrade your C++ projects to the latest Windows 10
SDK. If you have a hard dependency on 8.1, you can download it from
the Windows SDK archive.
So download and install the SDK from here.
I have a problem getting Xamarin.Android to target the newest version of Android.
The problem arised when I tried installing the Xamarin.GooglePlayServices.Maps NuGet package, that required me to run at least Android 8.
From my Android SDK manager, I can see that Android 8 and 8.1 is the only SDK platforms installed:
However, when I start a new project in Visual Studio 2017, and go into the project properties, and extend the Compile using Android version dropdown, it's populated like this:
So here I can choose only 7.1 (that is marked as latest platform), and 8.0 and 8.1 is marked with (Requires installation). Android 7.1 SDK that VS uses is not even installed on my machine.
So the questions is: What do I have to do to select Android 8.1 as the Target Framework inside Visual Studio?
What do I have to do to select Android 8.1 as the Target Framework inside Visual Studio?
In your VS, Tools->Android->Android SDK Manager, you will see Android SDK for VS, it default path is C:\Program Files (x86)\Android\android-sdk.
In your AS, Android SDK's path is C:\Users\user name\AppData\Local\Android\Sdk
Now, you can change the VS's Android SDK's path to C:\Users\user name\AppData\Local\Android\Sdk, but we don't suggest you do that, it may cause VS compilation errors at some point, and by then you cannot find the cause of the problem.
So, you can download the Android 8 from VS again.
I'd like to debug my iOS app using an older version of the Mono framework so that I can see how things behaved with an older version of the Mono.Data.Sqlite assembly.
How can I tell Xamarin Studio to use an older version?
You can assign MD_MTOUCH_SDK_ROOT to point to an alternative install location. This should be the root directory that contains bin/mtouch.
You can set/export this as an env. variable to points to your alternative Xamarin.iOS framework and then launch Xamarin Studio (or VS4M) from the same shell.
Or you could assign it within your .csproj file.
Ref: Xamarin.MonoTouch.CSharp.targets
You can downgrade to an earlier version of Xamarin simply by running an older installer. Here's more information on where to find the installers and how to use them: How do I downgrade to an older version of Xamarin?