title: Eclipse-The following classes could not be instantiated: - android.support.v7.widget.RecyclerView
body: <p>I am trying to use recycler view but eclipse  giving error:...my support libraries are up-to-date :</p>
  
  <p>This is Error:</p>
  
  <p><a href="https://i.stack.imgur.com/vxeOE.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/vxeOE.png" alt="enter image description here"></a></p>
  
  <p>here is my layout that adding recycler-view :.</p>
  
  <p>//part of 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"
  xmlns:tools="http://schemas.android.com/tools"
      xmlns:widget="http://schemas.android.com/apk/res-auto"
      xmlns:custom="http://schemas.android.com/apk/res-auto"
      android:layout_height="match_parent" 
      android:id="@+id/playeramainlayout"
      android:background="@color/black"&gt; 
  
      &lt;LinearLayout
          android:id="@+id/hf "
          android:layout_width="match_parent"
          android:layout_height="100dp"
          android:layout_alignParentBottom="true"
          android:background="@color/black"
          android:gravity="center" &gt;
  
        &lt;!-- Player Buttons --&gt;
          &lt;LinearLayout 
              android:layout_width="wrap_content"
              android:layout_height="wrap_content"
              android:orientation="horizontal"
              android:gravity="center_vertical"
              android:background="@layout/rounded_corner"
              android:paddingLeft="10dp"
              android:paddingRight="10dp"&gt;
              &lt;!-- Previous Button --&gt;
              &lt;ImageButton
                  android:id="@+id/btnPrevious" 
                  android:src="@drawable/btn_previous"
                  android:layout_width="wrap_content"
                  android:layout_height="wrap_content"
                  android:background="@null"/&gt;
              &lt;!-- Play Button --&gt;
  
              &lt;ImageButton
                  android:id="@+id/btnPlay"
                  android:layout_width="wrap_content"
                  android:layout_height="wrap_content"
                  android:background="@null"
  
                  android:src="@drawable/btn_play" /&gt;
  
  
                  android:background="@null"/&gt;
              &lt;!-- Next Button --&gt;
              &lt;ImageButton 
                  android:id="@+id/btnNext"
                  android:src="@drawable/btn_next"
                  android:layout_width="wrap_content"
                  android:layout_height="wrap_content"
                  android:background="@null"/&gt;
  
          &lt;/LinearLayout&gt;
      &lt;/LinearLayout&gt;
  
      &lt;!-- Progress Bar/Seek bar --&gt;
      &lt;!-- Timer Display --&gt;
  
      &lt;FrameLayout
          android:id="@+id/imageviewkalayout"
          android:layout_width="match_parent"
          android:layout_height="wrap_content"
          android:layout_above="@+id/player_header_bg"
          android:layout_alignParentRight="true"
          android:layout_alignParentTop="true"
          android:gravity="center"
          android:paddingBottom="10dp"
          android:paddingTop="10dp" &gt;
  
      &lt;android.support.v7.widget.RecyclerView
          android:id="@+id/HSVfoalbumarinplayeractivity"
          android:layout_width="match_parent"
          android:layout_height="match_parent" &gt;
         &lt;/android.support.v7.widget.RecyclerView&gt;   
          &lt;ImageButton
              android:id="@+id/btnRepeat"
              android:layout_width="wrap_content"
              android:layout_height="wrap_content"
              android:layout_marginRight="5dp"
              android:background="@null"
              android:src="@drawable/btn_repeat" /&gt;
  
          &lt;ImageButton
              android:id="@+id/btnShuffle"
              android:layout_width="wrap_content"
              android:layout_height="wrap_content"
              android:layout_marginLeft="65dp"
              android:background="@null"
              android:src="@drawable/btn_shuffle" /&gt;
  
          &lt;ImageButton
              android:id="@+id/equaliser"
              android:layout_width="wrap_content"
              android:layout_height="wrap_content"
              android:layout_marginLeft="130dp"
              android:background="@null"
              android:src="@drawable/btn_repeat" /&gt;
  
      &lt;/FrameLayout&gt;
  
      &lt;LinearLayout
          android:id="@+id/timerDisplay"
          android:layout_width="fill_parent"
          android:layout_height="wrap_content"
          android:layout_above="@+id/songProgressBar"
          android:layout_centerHorizontal="true"
          android:background="@color/black" &gt;
  
          &lt;TextView
              android:id="@+id/songCurrentDurationLabel"
              android:layout_width="match_parent"
              android:layout_height="match_parent"
              android:layout_weight="1"
              android:gravity="left"
              android:background="@color/black"
  
              android:textColor="#eeeeee"
              android:textStyle="bold" /&gt;
  
          &lt;TextView
              android:id="@+id/songTotalDurationLabel"
              android:layout_width="155dp"
              android:layout_height="match_parent"
              android:background="@color/black"
              android:gravity="right"
              android:textColor="#eeeeee"
              android:textStyle="bold" /&gt;
      &lt;/LinearLayout&gt;
  
      &lt;SeekBar
          android:id="@+id/songProgressBar"
          android:layout_width="fill_parent"
          android:layout_height="wrap_content"
          android:layout_above="@+id/  hf "
          android:layout_alignParentLeft="true"
          android:background="@color/black"
          android:paddingLeft="6dp"
          android:paddingRight="6dp"
          android:progressDrawable="@drawable/seekbar_progress"
          android:thumb="@drawable/seek_handler" /&gt;
  
      &lt;RelativeLayout
          android:id="@+id/player_header_bg"
          android:layout_width="fill_parent"
          android:layout_height="60dip"
          android:layout_above="@+id/timerDisplay"
          android:layout_alignParentLeft="true"
          android:background="@color/black"
          android:paddingLeft="5dp"
          android:paddingRight="5dp" &gt;
  
          &lt;TextView
              android:id="@+id/songTitle"
              android:layout_width="match_parent"
              android:layout_height="30dp"
              android:layout_weight="1"
              android:gravity="center"
              android:singleLine="true" /&gt;
  
          &lt;TextView
              android:id="@+id/songartist"
              android:layout_width="wrap_content"
              android:layout_height="wrap_content"
              android:layout_alignParentBottom="true"
              android:layout_alignParentLeft="true"
              android:layout_alignParentRight="true"
              android:gravity="center"
              android:singleLine="true" /&gt;
      &lt;/RelativeLayout&gt;
  
  &lt;/RelativeLayout&gt;
  </code></pre>
  
  <p>Here is the code oof initialising view that is adding recycler view to activity :</p>
  
  <pre><code>@Override
      public void onCreate(Bundle savedInstanceState) {
          requestWindowFeature(Window.FEATURE_NO_TITLE);
           requestWindowFeature(Window.FEATURE_INDETERMINATE_PROGRESS);
  
          super.onCreate(savedInstanceState);
  
          setContentView(R.layout.player);
  
          HSVforimageGallery=(RecyclerView) findViewById(R.id.HSVfoalbumarinplayeractivity);
          HSVforimageGallery.setLayoutManager(new LinearLayoutManager(this));
          HSVforimageGallery.setHasFixedSize(true);
  }
  </code></pre>
  
  <p>Here is logcat :</p>
  
  <pre><code>12-28 21:40:32.055: E/AndroidRuntime(25525): FATAL EXCEPTION: main
  12-28 21:40:32.055: E/AndroidRuntime(25525): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.androidhive.musicplayer/com.androidhive.musicplayer.AndroidBuildingMusicPlayerActivity}: android.view.InflateException: Binary XML file line #113: Error inflating class android.support.v7.widget.RecyclerView
  12-28 21:40:32.055: E/AndroidRuntime(25525): Caused by: android.view.InflateException: Binary XML file line #113: Error inflating class android.support.v7.widget.RecyclerView
  
  12-28 21:40:32.055: E/AndroidRuntime(25525):    at android.app.Activity.setContentView(Activity.java:1881)
  12-28 21:40:32.055: E/AndroidRuntime(25525):    at com.androidhive.musicplayer.AndroidBuildingMusicPlayerActivity.onCreate(AndroidBuildingMusicPlayerActivity.java:114)
  12-28 21:40:32.055: E/AndroidRuntime(25525): Caused by: java.lang.NoClassDefFoundError: android.support.v7.recyclerview.R$styleable
  12-28 21:40:32.055: E/AndroidRuntime(25525):    at android.support.v7.widget.RecyclerView.&lt;init&gt;(RecyclerView.java:481)
  12-28 21:40:32.055: E/AndroidRuntime(25525):    at android.support.v7.widget.RecyclerView.&lt;init&gt;(RecyclerView.java:450)
  12-28 21:40:32.055: E/AndroidRuntime(25525):    ... 26 more
  </code></pre>
  
  <p>I tried lots of things like adding support project of recycler-view and referencing to main project etc .
  But none of the thing worked .</p>
  
  <p>Any help will be appreciated :).</p>