Questions tagged [xamarin.android]

Xamarin.Android (previously known as Mono for Android) is an implementation of Mono that runs on the Android platform, allowing you to write Android applications in C# using native Android libraries as well as using the .NET BCL (Base Class Libraries). Use this tag for issues that only occur when using Xamarin.Android, or when using Android-specific features.

Xamarin.Android (previously known as Mono for Android) is an implementation of Mono that runs on the Android platform, allowing you to write Android applications in C# using native Android libraries.

###Links:

18757 questions
25
votes
4 answers

Gradle dependencies in Xamarin

Is it possible to integrate dependencies from Gradle inside Xamarin project? A have some libraries, which I need to install, they look like this dependencies { compile (name: '', ext:'aar') compile…
Alexey K
  • 6,537
  • 18
  • 60
  • 118
24
votes
8 answers

Targeting/Developing for multiple mobile platforms with one programming language (C#)? Cost-Benefit?

Today it is possible to use C# programming for multiple mobile platforms such as: WindowPhone7 Android - Monodroid iPhone - Monotouch (feel free to edit if I missed some) Of course, it is still programming effort for UI, but main libraries of app…
nemke
  • 2,440
  • 3
  • 37
  • 57
24
votes
14 answers

Visual Studio 2017 - Xamarin - The file "obj\Debug\android\bin\packaged_resources" does not exist

I'm fighting with that issue for 2 days already and can't find any solution. I have an Xamarin Android app in Visual Studio 2017 consisting of three projects: Xamarin.Android project (main one) Android-specific unit tests run on the device -…
Dawid Sibiński
  • 1,657
  • 3
  • 21
  • 40
24
votes
1 answer

How to stop a process from System.Diagnostics.Process and get the statistics in the end

I'm using this code but when i stop the process it not get the ping statistics : System.Diagnostics.Process p = new System.Diagnostics.Process(); p.StartInfo.FileName = "ping"; p.StartInfo.Arguments = "-c " + count + " -i " + interval + " -s " +…
EAK TEAM
  • 5,726
  • 4
  • 30
  • 52
24
votes
4 answers

Get current app's build version - Xamarin.Android

I need to display the app's build version in my settings page. So how can i get the versionCode and versionName from AndroidManifest.xml file programmatically. Or Is there any way to get the build version programmatically in xamarin.forms.
Tushar patel
  • 3,279
  • 3
  • 27
  • 30
24
votes
4 answers

Xamarin DependencyService: System.MissingMethodException: Default constructor not found for [Interface]

I am receiving this error when using the Dependency Service on a Xamarin.Forms PCL. I have seen answers to this error that involve iOS and the Linker. However, I am running this on Android and the Linker is off. Debug mode as well. The constructor…
24
votes
7 answers

System.ObjectModel Warning Xamarin does not run on Android

We are running the 'Welcome to Xamarin` example on Visual Studio Enterprise, using the latest Xamarin, in a Windows 8.1 environment. We are managing to build and run on both Windows and Apple, but we are facing problems with Android. Error: The…
Neil Camilleri
  • 243
  • 1
  • 3
  • 6
24
votes
1 answer

How to register my own Application subclass in Xamarin.Android?

I have public class MyApp : Application In Java I would add a line to the manifest and pass it the namespace and name of my application:
Krumelur
  • 32,180
  • 27
  • 124
  • 263
24
votes
1 answer

Xamarin.Android builds/deployments are very slow. How to speed them up?

We have a large Xamarin.Android project with two depending projects and a bunch of third party dll's. Doing a debug deployment (without any changes) onto a Hax-x86 Emulator or a Nexus 5 device is painfully slow (> 80 seconds). For comparison the…
Rodja
  • 7,998
  • 8
  • 48
  • 55
24
votes
3 answers

Using a ValueAnimator to make a TextView blink different colors

I want to use a ValueAnimator to make a TextView's text color blink twice between two different colors but I want to create the Animation in XML. I cannot find any examples. Any help will be appreciated. Update The code below works perfect. The…
wheels53
  • 719
  • 1
  • 7
  • 21
23
votes
3 answers

Xamarin - This release is not compliant with the Google Play 64-bit requirement

I archived and deployed my apk in Visual Studio to the Google play store but it wouldn't let me continue with Beta rollout and the only message on the beta rollout page was the following warning: After clicking the error the next message came…
Post Impatica
  • 14,999
  • 9
  • 67
  • 78
23
votes
7 answers

Unable to create new Blank App (Android) in Visual Studio 2015

I am trying to create a new Blank App (Android) in Visual Studio 2015 with installed Xamarin, Android SDK and Android emulator. When trying to create a new Project, I just get a popup with the message: Value cannot be null. Parameter name:…
Parham.D
  • 1,158
  • 2
  • 12
  • 31
23
votes
2 answers

Cross Platform Logging in Xamarin

I am looking for either a logging utility such as NLog, Log4Net, etc... that will allow me to log in my Xamarin.Andriod, Xamarin.IOS, and a Xamarin.PCL project. All of the loggers I have looked at so far are not supported in the PCL projects for…
user3430360
  • 261
  • 1
  • 2
  • 6
22
votes
17 answers

The type initializer for 'SQLite.SQLiteConnection' threw an exception

I'm trying to implement an incredibly basic use of SQLite. I have a Button and an EditText. I want to store the contents of the EditText OnClick. I'm following this:…
Jacob Barnes
  • 1,480
  • 1
  • 12
  • 29
22
votes
4 answers

Obfuscation in Xamarin Projects

As you know Xamarin projects are compiled into dot net dll assembly and it'll be pack into apk file and can be easily reflected by reflectors like DotPeek. My first question is: How can we protect our code? My second question is: Do obfuscator tools…
Ali Bahrami
  • 5,935
  • 3
  • 34
  • 53