πŸš€ go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.jbuilder.java.language
Article #7516

Re: Call a .bat

#7516
From: Nabin Thomas
Date: Sun, 17 Jun 2001 16:03
58 lines
2517 bytes
TRY
 Runtime.getRuntime().exec("start batchfile.bat");

icsd.jt@wanadoo.fr wrote:

> Hello
> I have try this
>    ...
>     Runtime rt=Runtime.getRuntime();
>     try
>     {
>     Process proc = rt.exec(".\\xxx.bat");
>   ...
>   ( The file xxx.bat is in the directory of the .jpx
>      and naturaly this xxx.bat run alone correctly )
> A DOS windows is effectively open but he is
> empty : the .bat does not run.
> Have you an idea ?
> I have try this in NT5 (Windows Pro 2000)
> Thank , Jacques
>
> "John McGrath [TeamB]" <ng-b@JPMcGrath.net> a Γ©crit dans le message news:
> MPG.15407bdc296cf9bd98a11a@forums.borland.com...
> > On Tue, 10 Apr 2001 17:55:03 +0200, icsd.jt@wanadoo.fr wrote:
> >
> > > what is the best way for call a xxx.bat from an
> > > JB4 appli ?
> >
> > To call a bat file from a Java application, use the Runtime exec()
> > method.
> >
> > --
> > Regards,
> >
> > John McGrath [TeamB]
> >
> > ---------------------------------------------------
> > Before sending me e-mail, please read:
> >     http://www.JPMcGrath.net/newsgroups/e-mail.html

--
        ***********************************
***************************************************
******************* Web Card **********************
***************************************************

Name :   Nabin Thomas

e-mail :   nabinthomas@hotmail.com

Web :   http://nabin.topcities.com

Feel free to contact me thru e-mail or MSN Mssenger
if required but DONOT SPAM

***************************************************
 ***********************************
Technical Details
Message-ID: <3B2CD4CF.C63077D@hotmail.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!newsfeed.google.com!sn-xit-02!supernews.com!newsfeed.direct.ca!look.ca!netnews.com!newsfeed.wirehub.nl!PeerFeed.KWeb.on.ca!dnews
References: <3ad32ca1$1_2@dnews> <MPG.15407bdc296cf9bd98a11a@forums.borland.com> <3add2ebb_2@dnews>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII
X-Google-Thread: f74b3,1b19f5d9dbd32d49
X-Google-Attributes: gidf74b3,public
X-Google-ArrivalTime: 2001-06-18 04:08:15 PST
Message-ID: <3B2CD4CF.C63077D@hotmail.com>
Date: Sun, 17 Jun 2001 21:33:28 +0530
From: Nabin Thomas <nabinthomas@hotmail.com>
X-Mailer: Mozilla 4.75 [en] (Win98; U)
X-Accept-Language: en
MIME-Version: 1.0
Newsgroups: borland.public.jbuilder.java.language
Subject: Re: Call a .bat
References: <3ad32ca1$1_2@dnews> <MPG.15407bdc296cf9bd98a11a@forums.borland.com> <3add2ebb_2@dnews>
Content-Type: text/plain; charset=iso-8859-1
Content-Transfer-Encoding: quoted-printable
NNTP-Posting-Host: 202.86.154.28
X-Trace: dnews 992862298 202.86.154.28 (18 Jun 2001 04:04:58 -0700)
Lines: 61
Path: arc1-ca.pugleaf.net!archiver1.google.com!newsfeed.google.com!sn-xit-02!supernews.com!newsfeed.direct.ca!look.ca!netnews.com!newsfeed.wirehub.nl!PeerFeed.KWeb.on.ca!dnews