Board index » delphi » How-to Close DOS Windows in DEPLphi

How-to Close DOS Windows in DEPLphi

I'm executing a DOS aplication from my program (with executefile( )),
when the programs end, his window is open. I need to execute a lots of
DOS aplication (like compressers) from my program. How could i close
this windows from DELPHI. There is some comand
like 'closewindows after exit DOS program'?

Sorry about my english, i'm brazilian. I wait you understood my problem!

best REgards
Rodrigo

 

Re:How-to Close DOS Windows in DEPLphi


Not sure about in code but you could create a PIF file or shortcut in 95
for each DOS app and set it to close on exit.

Simon Croucher

Quote
Jurgen Bartels wrote:
> >I'm executing a DOS aplication from my program (with executefile( )),
> >when the programs end, his window is open. I need to execute a lots of
> >DOS aplication (like compressers) from my program. How could i close
> >this windows from DELPHI. There is some comand
> >like 'closewindows after exit DOS program'?

> I have exactly the same problem, and found no solution.
> When I use 4DOS, everything works as expected, and I also get the
> Errorlevel back from the .EXE that 4DOS runs. With COMMND.COM I always
> get back 0. It seems COMMAND.COM is not working properly?

> Jurgen

> Jurgen Bartels, Taunusstein near Wiesbaden, Germany
> jurg...@rheingau.netsurf.de

Re:How-to Close DOS Windows in DEPLphi


In article <346ec8d9.2178...@news.rheingau.netsurf.de>,
jurg...@rheingau.netsurf.de says...

Quote
> I have exactly the same problem, and found no solution.
> When I use 4DOS, everything works as expected, and I also get the
> Errorlevel back from the .EXE that 4DOS runs. With COMMND.COM I always
> get back 0. It seems COMMAND.COM is not working properly?

 Solution for COMMAND.COM is very simple, for example, if you are using
PKZIP.EXE, open windows explorer and find it on the disk, then right
click, properties, click on PROGRAM and check "CLOSE ON EXIT"...

  BDM

Other Threads