未找到 Android 类:未找到类...在路径上:DexPathList:类链接失败: [英] Android Class not found : Didn't find class ... on path: DexPathList : link of class failed :

查看:60
本文介绍了未找到 Android 类:未找到类...在路径上:DexPathList:类链接失败:的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在 github 项目的指导下从事社交网络的工作.我有一个名为 SocialMainActivity 的主要活动,它们将 OAuth 作为 lib 导入,OAuth 将 facebook lib、facebool lib 导入 google-play-service 和 support-v7 作为 lib.

I am doing work on social network under guidence of github project on it. I have main activity named SocialMainActivity that import OAuth as lib and OAuth import facebook lib, facebool lib import google-play-service and support-v7 as lib.

  • 我删除了多个 jar 文件并将所有 jar 文件存储在 facebook lib 中,

因此成功删除了 jar 文件上的错误多个 dex 文件.但是在删除该错误后,我面临新的错误

so success to remove error multiple dex file, on jar file. But after remove that error i face new error

Class not found SocialMainActivity on path: DexPathList etc. 

我在谷歌上搜索并遵循所有这一步,但我没有成功.那么有人可以帮我解决这个错误吗?

I so much googling and follow all that step but i not success ed. So any one can help me to solve this error?

主要活动属性和项目结构

Main activity properties and projects structures

推荐答案

解决方案 1:

您更改了库或 .jar 文件.所以重新启动日食.

You changed your libs or .jar files. So Restart the Eclipse.

解决方案 2:

右键单击您的项目并选择属性.这属性" 面板将打开.从左侧的菜单转到Java 构建路径 ->订购和导出.从下面的列表中取消选中Android 依赖项" 旁边的框.最后清理你的项目并运行.

Right click on your project and select properties. The "Properties for " panel will open. From the menu on the left go to Java Build Path -> Order and Export . From the list below uncheck the box next to "Android Dependencies". Finally clean your project and run.

解决方案 3:

创建一个新项目并将所有内容从这个项目复制到新项目.

Create a new project and copy everything from this one to the new one.

解决方案 4:

再次查看您的课程 SocialMainActivity.检查它的活动,您是否在清单文件中将其声明为反对片段.检查这个类的布局xml.Android 布局文本区分大小写,因此请仔细检查所有内容.

View your class SocialMainActivity again. Check that if its activity, did you declared it in your manifest file as oppose to fragment. Check the layout xml of this class. Android layout text is case sensitive so check everything carefully.

多个dex文件定义Lcom/facebook/AccessToken$SerializationProxyV1;

Multiple dex files define Lcom/facebook/AccessToken$SerializationProxyV1;

好吧,这取决于您是仅构建 Facebook SDK,还是将其作为库包含在您自己的 Android 项目中(我想是这种情况).如果您的项目文件夹中有一些 JAR(作为 JAR 添加到您的项目中),请将它们删除并将它们复制到项目根目录之外的某个位置,然后再次将它们添加为外部 jar.

Well, it depends if you build the Facebook SDK only, or you've included it as Library for your own Android project (I suppose that's the case). If you have some JAR's within your project folder (added as JARs to your project), remove them and copy them somewhere outside your project root, then add them again as the external jars.

检查 - conversion-to-dalvik-format-failed-facebook-accesstokenserializationproxyv1.

这篇关于未找到 Android 类:未找到类...在路径上:DexPathList:类链接失败:的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆