Winamp & Shoutcast Forums

Winamp & Shoutcast Forums (http://forums.winamp.com/index.php)
-   NSIS Discussion (http://forums.winamp.com/forumdisplay.php?f=65)
-   -   Redirecting DOS output to current console (http://forums.winamp.com/showthread.php?t=248101)

Senser 7th June 2006 19:30

Redirecting DOS output to current console
 
I'm trying to redirect the output of a KiXtart script (running kix32 with the script as a parameter) to the current open DOS console window (if installer is started from a DOS command prompt)

The use for this: I'm creating a silent installer that contains kix32.exe and a kix script. These two files are extracted and then run, currently I'm using ExecWait and that works perfect. Only one thing I would like to improve: the installer should not a new DOS window if the installer is started from a DOS window, only if the installer is run from Explorer a new DOS window should be started. This way the look and feel of a command line tool is created by the installer.

I've already looked at ExecCmd, ExecDos and nsExec, great tools but I don't think I can use them in this case.

Hope I've made myself clear. :)

Afrow UK 7th June 2006 21:27

I don't think this is directly possible. The installer itself would have to be a console application to transfer output to the console window.

-Stu

Senser 8th June 2006 11:11

Hmm.. that's too bad. I've searched the forum for other solutions, but couldn't find anything usefull.

Takhir 8th June 2006 14:45

May be this is possible using wm_char, but this is not compatible with Win9x.
So you need a plug-in that can find installer' parent process and, if this is console, send kix command line to it's window and run it. May looks funny.
Another way - to hide kix process and send script output to parent console. ExecDos flushes output, so you can read log file to simulate 'alive output'. Not tested.

Senser 8th June 2006 15:07

@Takhir, thanks for the suggestions, I will definitely take a look at both!


All times are GMT. The time now is 04:43.

Copyright © 1999 - 2010 Nullsoft. All Rights Reserved.