码迷,mamicode.com
首页 > 移动开发 > 详细

You need to use a Theme.AppCompat theme (or descendant) with this activity解决方法

时间:2016-03-26 06:48:17      阅读:133      评论:0      收藏:0      [点我收藏+]

标签:

 

报错如下:
java.lang.RuntimeException: Unable to start activity ComponentInfo{com.example.test2/com.example.test2.MainActivity}: java.lang.IllegalStateException: You need to use a Theme.AppCompat theme (or descendant) with this activity.

解决方法:
创建的activity是MainActivity extends ActionBarActivity这样的。把后面的ActionBarActivity改成Activity,然后导包

You need to use a Theme.AppCompat theme (or descendant) with this activity解决方法

标签:

原文地址:http://www.cnblogs.com/hoge/p/5321855.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!