title: Avoiding/Preventing Unable to execute dex: method ID not in [0, 0xffff]: 65536 - Android Studio
body: <p>There are couples of solutions I found but none for me. I would want to avoid in hitting that, my project is never that big if I specifically get the classes that i need [A very uncomfortable way].</p>
  
  <p>My question is : Is it possible to exclude files[which had never been used in my project] that are in file dependency and module dependency in Android Studio? </p>
  
  <p>My project is referencing libraries such as </p>
  
  <ol>
  <li>Maven-Gplay Services</li>
  <li>Maven-SupportApp Compat</li>
  <li>Maven-v4</li>
  <li>Maven-crouton </li>
  <li>Maven-gson</li>
  <li>Maven-imageloader</li>
  <li>Maven-cwacmerge</li>
  <li>Maven-gcm-server</li>
  <li>Maven-facebook-android-api</li>
  <li>Maven-simple-xml</li>
  <li>Module-android-ngn-stack</li>
  <li>Module-my-other-lib</li>
  <li>Module-my-lib</li>
  <li>File-aws-android-sdk-2.0.5-ddb.jar</li>
  <li>File-aws-android-sdk-2.0.5-ddb-mapper.jar</li>
  <li>File-aws-android-sdk-2.0.5-core.jar</li>
  <li>File-mqtt-3.jar</li>
  </ol>
  
  <p>Now after I have added Module-android-ngn-stack, I hit the <code>Unable to execute dex: method ID not in [0, 0xffff]: 65536</code> , and the solution I found was a script in <code>xml</code> and proguard but these solutions only targets cure and not prevention. </p>
  
  <p>and question again :
  Is there any way that I could exclude some classes in File-dependency or Module dependency? like exclude <code>com.example.ClassthatArentUsed</code> in File or Module dependency? </p>
  
  <p>I hope i made myself clear and I hope there will be a prevention-like solution.</p>
  
  <p>Thanks.</p>