Go Back   PCMech Forums > Help & Discussion > Web Design / Development

Need Some Help? Type Your Keywords Here:

Reply
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
Old 05-01-2004, 12:37 PM   #1
Member (13 bit)
 
Floppyman's Avatar
 
Join Date: Mar 1999
Posts: 6,791
Closing Batch files

Hi all,

I need some help to get a batch file to close automatically once the program is launched. Here's the file:

@ECHO OFF
ECHO "This will launch the Myprogram Client."

CD C: \ProgramFiles\Myprogram\Client\
java -jar client.jar

Now once the JAR file launches the DOS windows stays open. I've tried to remedy this by entering @ECHO OFF followed by CLS, but the window still stays open. It seems that once the JAR file opens the Batch file will not want to on to the next line. Any ideas of this, or any other ideas how I can get the DOS window to close? TIA.
Floppyman is offline   Reply With Quote
Old 05-03-2004, 02:44 PM   #2
aym
Registered User
 
aym's Avatar
 
Join Date: Nov 2001
Posts: 1,965
Hi Floppyman,

Use javaw instead of java.
aym is offline   Reply With Quote
Old 05-08-2004, 12:46 AM   #3
Member (13 bit)
 
Floppyman's Avatar
 
Join Date: Mar 1999
Posts: 6,791
Thanks for the reply aym_7. I tried your suggestion but the window still stays open (even when I instert the CLS command again). TIA.
Floppyman is offline   Reply With Quote
Old 05-08-2004, 08:22 AM   #4
aym
Registered User
 
aym's Avatar
 
Join Date: Nov 2001
Posts: 1,965
Hi Floppyman,

Try this:
Code:
@ECHO OFF
ECHO "This will launch the Myprogram Client."

CD C:\ProgramFiles\Myprogram\Client\

start javaw -jar client.jar
It works under 2K/XP, not sure about 98/Me.

HTH
aym is offline   Reply With Quote
Reply

Bookmarks

Still Need Help? Type Your Keywords Here:


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

BB code is On
Smilies are On
[IMG] code is On
HTML code is On
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT -5. The time now is 12:54 AM.
Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2012, vBulletin Solutions, Inc.
SEO by vBSEO 3.6.0 PL2