Xamarin Studio (Android) Error Inflating Class <unknown> If Not Cleared

Problem:

After modifying any layout file in my Android project in Xamarin Studio, my mainlauncher (SplashActivity) throws the following exception. The exception continues until I clear my project.


An exception:

Binary String XML File # 17: Class Bloat Error

Exception being thrown


Environment:

I use the following tools:

Xamarin Studio: Version 5.2.1 (build 1)
Xamarin.Android: Version 4.1.0

With the following settings:

Minimum Android Version: Android 4.3 (API Level 16)

A computer:

Windows 7 Home Premium SP1 (x64)

Testing device:

Samsung Galaxy S4 is running Android 4.3


Relevant Code:

SplashLayout.axml:

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:orientation="vertical"
    android:layout_width="fill_parent"
    android:layout_height="fill_parent">
    <TextView
        android:text="Loading..."
        android:textAppearance="?android:attr/textAppearanceLarge"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:id="@+id/SPLASH_messageText" />
</LinearLayout>

SplashActivity (OnCreate only):

protected override void OnCreate (Bundle bundle)
{
    base.OnCreate (bundle);
    SetContentView (Resource.Layout.SplashLayout);   // <-- this is where the exception is thrown
    MessageTextView = FindViewById<TextView> (Resource.Id.SPLASH_messageText);      // Get a reference to our message text view to update the user

    ThreadPool.QueueUserWorkItem (o => {
        InitialChecking();               // Check to make sure Google Play services are installed
    });
} // end OnCreate

My research:

, , .


:

  • , , any.
  • , , .
  • XML , - . , SplashLayout.axml 12 .

:

  • ?
+4
1

axml: XMLNS: = "http://schemas.android.com/apk/res-auto"

, , .

0

All Articles