title: Android Studio error:- E/dalvikvm: Could not find class 'android.os.PersistableBundle'
body: <p>This is my MainActivity.java file:</p>
  
  <pre><code>package com.example.kushalpc.app1;
  import android.support.v7.app.AppCompatActivity;
  import android.os.Bundle;
  import android.view.View;
  import android.widget.Button;
  import android.widget.EditText;
  import android.widget.TextView;
  public class MainActivity extends AppCompatActivity {
      EditText userNameEditText;
      EditText passwordEditText;
      TextView userNameTextView;
      TextView passwordTextView;
      TextView resultTextView;
      CharSequence resultLoginSuccess = "Login Successful";
      CharSequence resultLoginFailed = "Login Failed";
      TextView createAccount;
      Button loginButton;
      @Override
      protected void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
          setContentView(R.layout.activity_main);
          userNameTextView = (TextView) findViewById(R.id.userName);
          passwordTextView = (TextView) findViewById(R.id.password);
          userNameEditText = (EditText) findViewById(R.id.userNameValue);
          passwordEditText = (EditText) findViewById(R.id.passwordValue);
          resultTextView = (TextView) findViewById(R.id.resultTextView);
          loginButton = (Button) findViewById(R.id.loginButton);
          createAccount = (TextView) findViewById(R.id.createAccountTextView);
          createAccount.setOnClickListener(new View.OnClickListener() {
              @Override
              public void onClick(View view) {
                  setContentView(R.layout.registration);
              }
          });
          loginButton.setOnClickListener(new View.OnClickListener() {
              @Override
              public void onClick(View view) {
                  if(userNameEditText.getText().toString().equals("admin")
                          &amp;&amp; passwordEditText.getText().toString().equals("1234"))
                      resultTextView.setText(resultLoginSuccess);
                  else
                      resultTextView.setText(resultLoginFailed);
              }
          });
      }
  }
  </code></pre>
  
  <p>This is my RegistrationForm.java file</p>
  
  <pre><code>package com.example.kushalpc.app1;
  import android.os.Bundle;
  import android.support.v7.app.AppCompatActivity;
  import android.view.View;
  import android.widget.Button;
  import android.widget.TextView;
  public class RegistrationForm extends AppCompatActivity{
      Button goButton;
      TextView errorTextView;
      CharSequence c = "HEY";
      @Override
      protected void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
          setContentView(R.layout.registration);
          goButton = (Button) findViewById(R.id.goButton);
          errorTextView = (TextView) findViewById(R.id.emptyErrorTextView);
          goButton.setOnClickListener(new View.OnClickListener() {
              @Override
              public void onClick(View view) {
                  System.out.println(c);
              }
          });
      }
  }
  </code></pre>
  
  <p>ActivityMain.xml
      
      </p>
  
  <pre><code>    &lt;TextView
  
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:text="@string/userName"
          android:textSize="20sp"
          android:textStyle="bold"
          android:textColor="#000000"
          android:id="@+id/userName"
          /&gt;
  
      &lt;EditText
          android:layout_width="100dp"
          android:layout_height="wrap_content"
          android:id="@+id/userNameValue"
          android:layout_toEndOf="@+id/userName"
          android:textSize="14sp"
          android:textStyle="bold"
          android:layout_marginLeft="10dp"
          /&gt;
  
      &lt;EditText
          android:layout_width="100dp"
          android:layout_height="wrap_content"
          android:id="@+id/passwordValue"
          android:layout_below="@id/userName"
          android:layout_toEndOf="@+id/password"
          android:textSize="14sp"
          android:textStyle="bold"
          android:layout_marginStart="15dp"
          android:layout_marginTop="32dp"
          android:inputType="textPassword"
          /&gt;
      &lt;TextView
  
          android:layout_marginTop="40dp"
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:text="@string/password"
          android:textSize="20sp"
          android:textStyle="bold"
          android:textColor="#000000"
          android:layout_below="@id/userName"
          android:id="@id/password"
          /&gt;
  
      &lt;Button
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:layout_centerHorizontal="true"
          android:layout_below="@id/passwordValue"
          android:id="@+id/loginButton"
          android:text="@string/login"
          android:layout_marginTop="20dp"
          /&gt;
  
      &lt;TextView
  
          android:text="@string/createAccount"
          android:id="@+id/createAccountTextView"
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:textSize="15sp"
          android:layout_centerHorizontal="true"
          android:textStyle="italic"
          android:textColor="#000000"
          android:layout_below="@id/loginButton"
          android:clickable="true"
          /&gt;
  
      &lt;TextView
          android:layout_marginTop="140dp"
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:textSize="20sp"
          android:id="@+id/resultTextView"
          android:textStyle="bold"
          android:textColor="#000000"
          android:layout_below="@id/password"
          /&gt;
  
  &lt;/RelativeLayout&gt;
  </code></pre>
  
  <p>Registration.xml</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
      android:layout_width="match_parent"
      android:layout_height="match_parent"
      xmlns:tools="http://schemas.android.com/tools"
      android:layout_marginStart="40dp"
      android:layout_marginTop="60dp"
      android:layout_marginEnd="30dp"
      tools:Context="com.example.kushalpc.app1.RegistrationForm"&gt;
  
      &lt;TextView
  
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:text="@string/name"
          android:textSize="20sp"
          android:textStyle="bold"
          android:textColor="#000000"
          android:id="@+id/name"
  
          /&gt;
  
      &lt;TextView
  
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:text="@string/lastName"
          android:textSize="20sp"
          android:textStyle="bold"
          android:textColor="#000000"
          android:id="@+id/lastName"
          android:layout_below="@id/name"
          android:layout_marginTop="40dp"
          /&gt;
  
      &lt;TextView
  
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:text="@string/dateOfBirth"
          android:textSize="20sp"
          android:textStyle="bold"
          android:textColor="#000000"
          android:id="@+id/dateOfBirth"
          android:layout_below="@id/lastName"
          android:layout_marginTop="40dp"
          /&gt;
  
      &lt;TextView
  
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:text="@string/createPassword"
          android:textSize="20sp"
          android:textStyle="bold"
          android:textColor="#000000"
          android:id="@+id/createPassword"
          android:layout_below="@id/dateOfBirth"
          android:layout_marginTop="40dp"
          /&gt;
  
      &lt;TextView
  
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:text="@string/conformPassword"
          android:textSize="20sp"
          android:textStyle="bold"
          android:textColor="#000000"
          android:id="@+id/conformPassword"
          android:layout_below="@id/createPassword"
          android:layout_marginTop="40dp"
          /&gt;
  
      &lt;TextView
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:text="@string/createUserName"
          android:textSize="20sp"
          android:textStyle="bold"
          android:textColor="#000000"
          android:id="@+id/createUserName"
          android:layout_below="@id/conformPassword"
          android:layout_marginTop="40dp"
          /&gt;
  
      &lt;EditText
          android:layout_marginTop="-10dp"
          android:layout_width="100dp"
          android:layout_height="wrap_content"
          android:id="@+id/nameValue"
          android:textSize="14sp"
          android:textStyle="bold"
          android:layout_alignParentEnd="true"
          /&gt;
  
      &lt;EditText
          android:layout_width="100dp"
          android:layout_height="wrap_content"
          android:id="@+id/lastNameValue"
          android:textSize="14sp"
          android:textStyle="bold"
          android:layout_below="@id/name"
          android:layout_marginTop="30dp"
          android:layout_alignParentEnd="true"
          /&gt;
  
      &lt;EditText
          android:layout_width="100dp"
          android:layout_height="wrap_content"
          android:id="@+id/dateOfBirthValue"
          android:inputType="date"
          android:textSize="14sp"
          android:textStyle="bold"
          android:layout_below="@id/lastName"
          android:layout_marginTop="30dp"
          android:layout_alignParentEnd="true"
          /&gt;
  
      &lt;EditText
          android:layout_width="100dp"
          android:layout_height="wrap_content"
          android:id="@+id/createPasswordValue"
  
          android:textSize="14sp"
          android:textStyle="bold"
  
          android:layout_below="@id/dateOfBirth"
          android:layout_marginTop="30dp"
          android:layout_alignParentEnd="true"
          /&gt;
  
      &lt;EditText
          android:layout_width="100dp"
          android:layout_height="wrap_content"
          android:id="@+id/conformPasswordValue"
          android:textSize="14sp"
          android:textStyle="bold"
          android:layout_below="@id/createPassword"
          android:layout_marginTop="30dp"
          android:layout_alignParentEnd="true"
  
          /&gt;
  
      &lt;EditText
          android:layout_width="100dp"
          android:layout_height="wrap_content"
          android:id="@+id/createUserNameValue"
          android:textSize="14sp"
          android:textStyle="bold"
          android:layout_below="@id/conformPassword"
          android:layout_marginTop="30dp"
          android:layout_alignParentEnd="true"
          /&gt;
  
  
      &lt;Button
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:layout_centerHorizontal="true"
          android:layout_below="@id/createUserNameValue"
          android:layout_alignEnd="@id/createUserNameValue"
          android:id="@+id/goButton"
          android:text="@string/go"
          android:layout_marginTop="15dp"
          /&gt;
      &lt;!--
  
          &lt;Button
              android:layout_width="wrap_content"
              android:layout_height="wrap_content"
              android:layout_centerHorizontal="true"
              android:layout_below="@id/createUserName"
              android:layout_alignStart="@id/createUserName"
              android:id="@+id/exitButton"
              android:text="@string/exit"
              android:layout_marginTop="20dp"
              /&gt;--&gt;
  
  
      &lt;TextView
  
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:textSize="20sp"
          android:layout_below="@+id/goButton"
          android:textStyle="bold"
          android:text="sample"
          android:textColor="#000000"
          android:id="@+id/emptyErrorTextView"
          /&gt;
          &lt;!--android:layout_below="@id/exitButton"
          android:layout_marginTop="40dp"
          --&gt;
  
  &lt;/RelativeLayout&gt;
  </code></pre>
  
  <p>When I run my code following are log cat error in red:</p>
  
  <blockquote>
    <ul>
    <li><p>07-08 11:44:38.704 1578-1578/com.example.kushalpc.app1 E/dalvikvm: Could not find class 'android.os.PersistableBundle', referenced from
    method com.example.kushalpc.app1.MainActivity.access$super</p></li>
    <li><p>07-08 11:44:38.704 1578-1578/com.example.kushalpc.app1 E/dalvikvm: Could not find class 'android.os.PersistableBundle', referenced from
    method com.example.kushalpc.app1.MainActivity.access$super</p></li>
    </ul>
    
    <p>-07-08 11:44:38.704 1578-1578/com.example.kushalpc.app1 E/dalvikvm: Could not find class 'android.media.session.MediaController',
    referenced from method
    com.example.kushalpc.app1.MainActivity.access$super</p>
    
    <p>-07-08 11:44:38.712 1578-1578/com.example.kushalpc.app1 E/dalvikvm: Could not find class 'android.widget.Toolbar', referenced from method
    com.example.kushalpc.app1.MainActivity.access$super</p>
    
    <p>-07-08 11:44:38.712 1578-1578/com.example.kushalpc.app1 E/dalvikvm: Could not find class 'android.app.ActivityManager$TaskDescription', referenced from method > com.example.kushalpc.app1.MainActivity.access$super</p>
    
    <p>-07-08 11:44:38.720 1578-1578/com.example.kushalpc.app1 E/dalvikvm: Could not find class 'android.app.SharedElementCallback', referenced
    from method com.example.kushalpc.app1.MainActivity.access$super</p>
    
    <p>-07-08 11:44:38.720 1578-1578/com.example.kushalpc.app1 E/dalvikvm: Could not find class 'android.os.PersistableBundle', referenced from
    method com.example.kushalpc.app1.MainActivity.access$super</p>
    
    <p>-07-08 11:44:38.720 1578-1578/com.example.kushalpc.app1 E/dalvikvm: Could not find class 'android.app.SharedElementCallback', referenced from method >com.example.kushalpc.app1.MainActivity.access$super</p>
    
    <p>-07-08 11:44:38.736 1578-1578/com.example.kushalpc.app1 E/dalvikvm: Could not find class 'android.app.assist.AssistContent', referenced from method 
    com.example.kushalpc.app1.MainActivity.access$super</p>
    
    <p>-07-08 11:44:38.736 1578-1578/com.example.kushalpc.app1 E/dalvikvm: Could not find class 'android.view.SearchEvent', referenced from method 
    com.example.kushalpc.app1.MainActivity.access$super</p>
    
    <p>-07-08 11:44:38.744 1578-1578/com.example.kushalpc.app1 E/dalvikvm: Could not find class 'android.os.PersistableBundle', referenced from method 
    com.example.kushalpc.app1.MainActivity.access$super</p>
    
    <p>-07-08 11:44:47.180 1578-1578/com.example.kushalpc.app1 E/OpenGLRenderer: Getting MAX_TEXTURE_SIZE from GradienCache 07-08
    11:44:47.188 1578-1578/com.example.kushalpc.app1 E/OpenGLRenderer:
    MAX_TEXTURE_SIZE: 8192 07-08 11:44:47.244
    1578-1578/com.example.kushalpc.app1 E/OpenGLRenderer: Getting
    MAX_TEXTURE_SIZE from Caches::initConstraints() 07-08 11:44:47.244
    1578-1578/com.example.kushalpc.app1 E/OpenGLRenderer:
    MAX_TEXTURE_SIZE: 8192</p>
    
    <p>-07-08 11:44:47.336 1578-1578/com.example.kushalpc.app1 E/dalvikvm: Could not find class 'android.graphics.drawable.RippleDrawable',
    referenced from method
    android.support.v7.widget.AppCompatImageHelper.hasOverlappingRendering</p>
    
    <ul>
    <li>07-08 11:49:31.865 5587-5587/com.example.kushalpc.app1 E/OpenGLRenderer: Getting MAX_TEXTURE_SIZE from GradienCache 07-08
    11:49:31.869 5587-5587/com.example.kushalpc.app1 E/OpenGLRenderer:
    MAX_TEXTURE_SIZE: 8192 07-08 11:49:31.885
    5587-5587/com.example.kushalpc.app1 E/OpenGLRenderer: Getting
    MAX_TEXTURE_SIZE from Caches::initConstraints() 07-08 11:49:31.893
    5587-5587/com.example.kushalpc.app1 E/OpenGLRenderer:
    MAX_TEXTURE_SIZE: 8192</li>
    </ul>
    
    <p>-07-08 11:49:31.917 5587-5587/com.example.kushalpc.app1 E/dalvikvm: Could not find class 'android.graphics.drawable.RippleDrawable',
    referenced from method
    android.support.v7.widget.AppCompatImageHelper.hasOverlappingRendering</p>
  </blockquote>