3

I am trying to convert one of my old APK's to a jar. 1. I downloaded apk tool in order to get the classes.dex file from my apk. 2. I downloaded dex2 jar and in the command line entered:

C:\Users\myLaptop\Downloads\dex2jar-2.0>dex2jar classes.dex

This lead to this Error:

dex2jar is not recognized as an internal or external command, operable program or batch file.

I am using a windows machine. I saw other questions posted on the issue on this site, when I tried them they didn't work. One solution was to use dex2jar version 0.0.9.15, but I got the same error when attempting to use that version.

Simeon Ikudabo
  • 2,152
  • 1
  • 10
  • 27

2 Answers2

1

I found the solution. If anyone is using dex2jar version 2.0 or higher, use this command in windows:

C:\Users\Zookeeper\Downloads\dex2jar-2.0>d2j-dex2jar classes.dex dex2jar classes.dex ->.\classes-dex2jar.jar

I now have a jar file from my apk

Simeon Ikudabo
  • 2,152
  • 1
  • 10
  • 27
0

If the above solution doesn't work, try this:

  1. Copy your .apk file into the dex2jar folder.
  2. Open terminal/cmd in that folder.
  3. Enter this command d2j-dex2jar.bat nameOfYourApkFile.apk

This way you will get a .jar file generated from the .apk file in that folder.