I am developing cross platform applications in VS2017. Recently I installed the latest VS and Android SDK Manager Updates and SDK Platforms.
Xamarin Android SDK: 18.104.22.168
Visual Studio Tools for Xamarin: 22.214.171.1240
Android SDK Tools: 25.2.5
Android SDK Platform-tools: 27.0.1
Android SDK Build-tools: 27.0.3
Besides several problems with the emulators and nuget packages that I solved more or less, I do not get the platform conditions to work as they did before.
#if __IOS__ int i; #elif __ANDROID__ int i; #else int i; #endif
I use these macros a lot in my shared lib to handle the platform specific stuff. VS opens the project and activates IOS for example. When I switch between the startup projects or platform... nothing happens. It remains IOS no matter what I do. The only workaround I discovered by now is unloading the platform projects that I don't need.
I did a repair installation of my VS, reset settings, tried different Android target version in the project settings, set up new projects to test if they behave the same. Nothing worked.