Multiple dex files define Lcom/google/ads/AdReques

2019-01-19 11:05发布

I created android application and try to add admob to it. but it not works. can anyone help me to fix this error.

[2014-04-09 15:16:51 - Dex Loader] Unable to execute dex: Multiple dex files define Lcom/google/ads/AdRequest$ErrorCode;
[2014-04-09 15:16:51 - Aurudhu_App] Conversion to Dalvik format failed: Unable to execute dex: Multiple dex files define Lcom/google/ads/AdRequest$ErrorCode;

This is the application architecture.

enter image description here

11条回答
叼着烟拽天下
2楼-- · 2019-01-19 11:25

I encountered this problem after adding google-play-services, but it was on a project that was not using the sdk for AdMob. After doing a clean rebuild, I stopped receiving this error. So if you are experiencing this, but are not using AdMob or still cannot figure it out for whatever reason, try doing a project clean rebuild. That is what worked for me.

查看更多
相关推荐>>
3楼-- · 2019-01-19 11:28

Eclipse project properties->Java build path->Order and export

Un-check Android private libraries.

查看更多
可以哭但决不认输i
4楼-- · 2019-01-19 11:28

You have imported google-play-services and used as library. you've also added google-play-services external jar files. So ambiguity. Do not use google-play-services as library.

查看更多
来,给爷笑一个
5楼-- · 2019-01-19 11:28

Go to Eclipse, Project -> Build ALL

Fixed the problem for me. I do not have Admob lib added, but got that issue. Cleaning build and BUILDING ALL fixed it for me.

查看更多
霸刀☆藐视天下
6楼-- · 2019-01-19 11:36

select project Rigth click on project--> Build Path --> Configure Build path--> Select libraries-->uncheck googleplaylib, and clean. and run, i hope it will work, I can solve my problem using this method. Try

查看更多
登录 后发表回答