Error inflating class and android.support.v7.widget.CardView

后端 未结 15 1625
-上瘾入骨i
-上瘾入骨i 2020-11-27 20:47

I want to use CardView in my project, but when I run my application, I get the following error. I\'m using Eclipse.

Error: Error inflating clas         


        
15条回答
  •  长情又很酷
    2020-11-27 21:19

    This solution work on me.

    1- Go to "sdk\extras\android\m2repository\com\android\support\recyclerview-v7*22.1.1*" ( 22.1.1 latest version for now. )

    2- Open recyclerview-v7-22.1.1.aar file with Winrar.

    3- There is a jar file named classes.jar. Copy that to your project libs folder.

    4- Right click classes.jar, add to build path.

    Thats it.

提交回复
热议问题