making jar file at run time?greenspun.com : LUSENET : Java Programming : One Thread |
hi I want to generate a jar file that will comprise of various .class files and a property file at run time i.e. when say user clicks on a button "make jar" jar should be created. How to do it?all efforts welcome. thanx shyamm@mahindrabt.com
-- shyamkant p matondkar (shyamm@mahindrabt.com,shyam_1978@yahoo.com), August 29, 2002
i will tell you but ....
this is a secret....
Agyat
-- Agyat (agyat_mitra@yahoo.com), February 19, 2004.
ok
-- Agyat (agyat_mitra@yahoo.com), February 19, 2004.
yayaya
-- pops (ppp@rediffmail.com), February 19, 2004.
//** save the following contents in "your.bat" file. jar cvfm my.jar MANIFEST.MF "MyClass1.class" "MyClass2.class" "MyClass3.class" "MyCla ss4.class"//** then execute bat file with following try { Runtime.getRuntime().exec("your.bat"); } catch(IOException ex) { ex.printStackTrace(); }
-- Naeem Shehzad Ghuman (naeemghuman@yahoo.com), October 04, 2004.