• 0

How do i edit a .class file and add it back into a .jar?


Question

Hey all,

I have a program in java that was made a while ago for me but my coder has gone awol. i need to be able to change a line in one of the .class files which is located within the .jar then i need to add it back into the .jar in order to run the program successfully.

I can extract the files using winrar and then edit the class file in notepad but a lot of the text is garbled. I have then tried creating an archive with the extension .jar instead of .rar but it wont work like that.

Does anybody know the best way to do this?

Thanks in advance

10 answers to this question

Recommended Posts

  • 0

hmm i have no idea whatsoever what i am doing with this program :s is there an easier program that will do it?

  divinatum said:
Jar files are zip files, rename to zip, extract, modify class, zip up, rename to .jar, should be good to go.

Hi and thanks for your reply. what should i edit the class with?

  • 0

Thanks monkey i was able to edit the class file with that program but now i am having troubles creating the .jar.

I am using winrar to create the archive and simply giving the extension of .jar but when i try to run it with cmd i get corrupt archive message

This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.