Java Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
 



Go Back   Dev Articles Community ForumsProgrammingJava Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Articles Community Forums Sponsor:
  #1  
Old July 19th, 2012, 05:10 AM
eshabali eshabali is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Jul 2012
Posts: 1 eshabali User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 10 m 21 sec
Reputation Power: 0
Want to load a jar file

I want to load a jar file by making a jar file loader through java code. please help.

Reply With Quote
  #2  
Old July 31st, 2012, 11:04 AM
lukwes1 lukwes1 is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Jul 2012
Posts: 3 lukwes1 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 11 m 50 sec
Reputation Power: 0
Re

String[] run = {"java","-jar", "C:/JarName.jar"}; //Setup
try {
Runtime.getRuntime().exec(run); // Runs the jar
} catch (Exception ex) {
ex.printStackTrace();
}
System.exit(0); //Shutdown the current program (Remove this line of code if you want the program to keep running)

Reply With Quote
  #3  
Old September 21st, 2012, 05:08 AM
jack hussey jack hussey is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Sep 2012
Posts: 1 jack hussey User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 4 m 54 sec
Reputation Power: 0
Loading jar Files

ProcessBuilder pb = new ProcessBuilder("/path/to/java", "-jar", "your.jar");
pb.directory(new File("preferred/working/directory"));
Process p = pb.start();

Reply With Quote
  #4  
Old October 23rd, 2012, 02:19 PM
rait56 rait56 is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Oct 2012
Posts: 2 rait56 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 24 m 5 sec
Reputation Power: 0
I dont know anything about this one....

Reply With Quote
  #5  
Old October 24th, 2012, 02:43 AM
Ba2rne7tte Ba2rne7tte is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Oct 2012
Posts: 1 Ba2rne7tte User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 m 42 sec
Reputation Power: 0
I want to load a jar file by making a jar file loader through java code. please help.

Reply With Quote
Reply

Viewing: Dev Articles Community ForumsProgrammingJava Development > Want to load a jar file


Developer Shed Advertisers and Affiliates


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.

© 2003-2018 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap