Android unable to execute dex : multiple dex files define Landroid

Posted on Updated on

Just today I started getting this exception:

unable to execute dex : multiple dex files define Landroid

Cause: This exception will come if you have multiple version of support library.

Where to check:

  1. Right Click on Project and select Build Path
  2. Check in Libraries if you have support library added (This happens when we do Android Tools -> Fix Project Properties)
  3. If you don’t find any such instance then check if you have copied support library manually into the lib folder of your project
  4. If you don’t find any such duplicates then check how many Android libraries (custom applications like FacebookSDK) 

Remove the duplicate libraries and do a clean -> rebuild

Hope this helps.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s