直接将android-support-v7-appcompat.jar包拷贝到项目的libs/下面是不能使用的,具体做法官方文档给出了详细说明:

(开发环境是ADT)

Using Eclipse

Create a library project based on the support library code:

  1. Make sure you have downloaded the Android Support Library using the SDK Manager.
  2. Create a library project and ensure the required JAR files are included in the project's build path:
    1. Select File > Import.
    2. Select Existing Android Code Into Workspace and click Next.
    3. Browse to the SDK installation directory and then to the Support Library folder. For example, if you are adding theappcompat project, browse to <sdk>/extras/android/support/v7/appcompat/.
    4. Click Finish to import the project. For the v7 appcompat project, you should now see a new project titled android-support-v7-appcompat.
    5. In the new library project, expand the libs/ folder, right-click each .jar file and select Build Path > Add to Build Path. For example, when creating the the v7 appcompat project, add both the android-support-v4.jar andandroid-support-v7-appcompat.jar files to the build path.
    6. Right-click the project and select Build Path > Configure Build Path.
    7. In the Order and Export tab, check the .jar files you just added to the build path, so they are available to projects that depend on this library project. For example, the appcompat project requires you to export both the android-support-v4.jar and android-support-v7-appcompat.jar files.
    8. Uncheck Android Dependencies.
    9. Click OK to complete the changes.

You now have a library project for your selected Support Library that you can use with one or more application projects.

Add the library to your application project:

  1. In the Project Explorer, right-click your project and select Properties.
  2. In the Library pane, click Add.
  3. Select the library project and click OK. For example, the appcompat project should be listed as android-support-v7-appcompat.
  4. In the properties window, click OK.

转载于:https://www.cnblogs.com/yshyee/p/3411693.html

android-support-v7-appcompat的配置使用相关推荐

  1. xamarin android 报错 Could not load assembly 'Xamarin.Android.Support.v7.AppCompat

    严重性 代码 说明 项目 文件 行 禁止显示状态 错误 Exception while loading assemblies: System.IO.FileNotFoundException: Cou ...

  2. android 4.2 noclassdeffounderror,NoClassDefFoundError:android.support.v7.internal

    运行Android 4.2的三星设备上的Android appcompat v7库存在问题.在我的开发者控制台中,我不断遇到以下堆栈跟踪崩溃: java.lang.NoClassDefFoundErr ...

  3. 一次解决找不到 android.support.v7.XXX 问题

    对于类似以下错误 Error inflating class android.support.v7.widget.RecyclerView Didn't find class "androi ...

  4. android v7支持库使用,正确引用 Android Support v7 兼容支持库

    这个问题昨天下午折腾了我老人家一下午,手动进行了各种组合,最终得以解决.现将步骤严格记录于此,以作备忘. 一.环境及前提 1.Windows 7/Mac OS X 10.9: 2.Eclipse 4. ...

  5. Android studio 实验过程中遇到的问题之android.support.v7.app.AppCompatActivity不能使用的解决办法

    android.support.v7.app.AppCompatActivity不能使用的解决办法 在构建项目时使用 android.support.v7.XX android.support.v4. ...

  6. android.support.v7.app.AlertDialog.Builder使用说明

    先看图        喜欢那种效果呢,左边是api22以下默认的,右边是android.support.v7.app.AlertDialog 用法说明: 1.改成v7的alertdialog andr ...

  7. 解决Android v4、v7包导入标红问题import android.support.v4.app.ActivityCompat;import android.support.v7.app

    解决Android v4.v7包导入标红问题 由于安卓经常性的升级,很多包都有过迁移,会造成有些包的路径变了. 如果有如下错误: import android.support.v4.app.Activ ...

  8. 安卓离线下载V7兼容包存在,但是无法import android.support.v7.app.AppCompatActivity

    很郁闷,有个权限问题需要用到v7兼容包,但一直导入失败. import android.support.v7.app.AppCompatActivity 通过SDK Manager在线安装Androi ...

  9. android.support.v7.app 包下载,“package android.support.v7.app does not exist” error in androidStudio...

    问题 i am just starting with android development using androidStudio i am following udacity tutorial w ...

  10. Binary XML file line #8: Error inflating class android.support.v7.widget.RecyclerView

    今天创建了一个 demo ,然后就是复制RecyclerView 过去, 到最后完成运行的时候发现 系统奔溃了, 然后 提示 Binary XML file line #8: Error inflat ...

最新文章

  1. 学习Python,这22个包怎能不掌握?
  2. div+css内容需注意
  3. 抽象工厂+反射=反射工厂
  4. 四:客服端防护HTTP发送请求类
  5. 现代的 “Hello, World”,可不仅仅是几行代码而已
  6. 判断某点在多边形内——方法一
  7. Java 将Excel转为XML
  8. NLPIR的语义分析系统
  9. 澳洲计算机专业几年,澳洲计算机硕士几年
  10. 超好看的Nteam官网PHP程序源码
  11. Conflux一周年 | 25分钟 VS 以太坊7个月,伍爷の硬核庆生
  12. 解决caffe编译时//usr/lib/x86_64-linux-gnu/libSM.so.6: undefined reference to `uuid_unparse_lower@UUI
  13. 四时之气,汇聚英豪胆略
  14. maven install、maven clean、project clean三者的区别
  15. MIRACL密码库分析报告3 mrio.c
  16. 关于Android 开发常用软件的快捷键总结
  17. 【内网安全-CS】Cobalt Strike启动运行上线方法插件
  18. Android 中屏幕点击事件的实现2
  19. Qt侧边垂直导航菜单栏Demo
  20. 通达信板块监控指标_通达信主力监控系统主图/副图指标公式

热门文章

  1. linux系统为什么很重要,为什么Linux系统始终取代不了Windows?这4个原因80%的人不知道!...
  2. java可选项_在Java中链接可选项8
  3. python创建person类用printinfo方法_python基础练习题7
  4. hbuilderx版本怎么更新到新版本_2.9版本快雪迎春更新公告
  5. python与室内设计_基于树莓派和Python的智能家居系统设计
  6. 需求获取安排计划书_若想成功融资,商业计划书必须秀色可餐:餐饮业商业计划书模板...
  7. 监测到本计算机上装有sql,检测局域网电脑是否有安装SQL Server数据库
  8. python发送qq消息linux_python 调用qq邮箱 linux 执行每天自动发送邮件
  9. 服务器虚拟化平台 可信云认证,100%满足规范,华为云Stack首批通过可信云虚拟化云平台最高等级认证...
  10. 计算机的五大组成部分(计组学习一)