Android 找不到 android-support-v7-appcompat.apk 错误
我一直在浏览开发者网站上的 android 教程,并在尝试向操作栏添加操作时运行(我正在使用支持库来支持 2.1+ 版本),我不断收到错误 android-support-v7-appcompat] 找不到 android-support-v7-appcompat.apk
!.
I have been going though the android tutorial on the developer site, and have run while trying to add actions to the Action bar (I am using the Support Library to support version 2.1+), I keep getting the error android-support-v7-appcompat] Could not find android-support-v7-appcompat.apk
!.
尽管操作栏没有我添加的按钮,但该应用程序仍然可以运行和运行.我已阅读有关此问题的其他帖子,并确保将 android-support-v7-appcompat 作为库包含在内.
The app still runs and functions, though the Action bar does not have the buttons I added. I've read other posts on this issue, and made sure that I included android-support-v7-appcompat as a library.
有什么我需要添加到构建路径的(不是按顺序导出,我已经在那里检查了它)?
Is there anything I need to add to the build path (not in order and export I already have it checked off there)?
谢谢!忘了提到我正在使用 eclipse,以防不清楚.在阅读了更多帖子之后,我的应用程序仍然运行似乎很奇怪,因为其他有这个问题的人都崩溃了.
Thanks! Forgot to mention that I am using eclipse in case it wasn't clear. After digging around reading some more posts, it seems strange that my app still runs since others with this problem have theirs crash.
注意:不确定这是否重要,但我必须在 main_activity_actions.xml(在 res/menu/中)中为 android:title = "@string/action_search" 手动添加字符串action_search" - 如果这是自动添加的使用 appcompat?
NOTE: Not sure if this matters but I had to manually add the string "action_search" for android:title = "@string/action_search" in main_activity_actions.xml (in res/menu/)- should this have been added automatically with appcompat?
下面的完整控制台输出:
Full console output below:
[2013-08-24 13:19:04 - MyFirstApp1] Android Launch!
[2013-08-24 13:19:04 - MyFirstApp1] adb is running normally.
[2013-08-24 13:19:04 - MyFirstApp1] Performing com.example.myfirstapp1.MainActivity activity launch
[2013-08-24 13:19:04 - MyFirstApp1] Automatic Target Mode: using existing emulator 'emulator-5554' running compatible AVD 'AVD1'
[2013-08-24 13:19:04 - MyFirstApp1] Uploading MyFirstApp1.apk onto device 'emulator-5554'
[2013-08-24 13:19:04 - MyFirstApp1] Installing MyFirstApp1.apk...
[2013-08-24 13:19:08 - MyFirstApp1] Success!
[2013-08-24 13:19:08 - android-support-v7-appcompat] Could not find android-support-v7-appcompat.apk!
[2013-08-24 13:19:08 - MyFirstApp1] Starting activity com.example.myfirstapp1.MainActivity on device emulator-5554
[2013-08-24 13:19:09 - MyFirstApp1] ActivityManager: Starting: Intent {
act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER]
cmp=com.example.myfirstapp1/.MainActivity
推荐答案
转到 Java Build Path > Projects 并删除不正确的项目依赖项(您的 Android 库项目.)请注意,在项目设置的Android"部分中您所依赖的 Android 库必须列在 ~"Libraries" 框中.
Go to Java Build Path > Projects and remove the incorrect project dependency (your Android library project.) Note that in the "Android" section of the project settings the Android library that you're dependent on must be listed in the ~"Libraries" box.
相关文章