Go Back   Winamp Forums > Developer Center > NSIS Discussion

Reply
Thread Tools Search this Thread Display Modes
Old 8th March 2006, 14:32   #1
coco_vc
Senior Member
 
Join Date: Jan 2006
Location: Germany
Posts: 138
Exec an exe and show a message until the app finishes

Hi all,

I need from my installer to run an exe. I use Exec or ExecWait and is doing what I need, but it shows the window of the application that I run, so in this case a ugly command prompt window

Can I somehow do the following:
- run myapp.exe with it's windows hidden
- while this one runs, show a msg like "Doing smth, pls wait ..."
?

So, something like:

code:

ShowMsg "Doing smth, please wait ..." TRUE ;puts a msg on the screen
ExecWait myapp.exe ;runs myapp.exe and waits to finish
ShowMsg "" FALSE ;removes the msg from the screen



Would this be possible?
Thx,
Viv
coco_vc is offline   Reply With Quote
Old 8th March 2006, 15:19   #2
coco_vc
Senior Member
 
Join Date: Jan 2006
Location: Germany
Posts: 138
I was able to actually find the answer in the forum, so I used the nsExec::Exec for this and seems is doing what I need.

Still 2 questions related to this subject:

1) In the docu is not written but as my tests show the nsExec::Exec waits (always) for the run exe to finish. Is this assumption correct?
2) Is there a way to run also Windows application with this and get them hidden or this will work only on console app? Is there smth that can be used to hide any window shown by the run application regardless if this is a console or a windows?

Thanks,
Viv
coco_vc is offline   Reply With Quote
Old 8th March 2006, 18:24   #3
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,337
To print a custom message, use DetailPrint. To suppress the message from ExecWait, use SetDetailsPrint.

nsExec will only hide the output of command line applications.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 10th March 2006, 10:35   #4
coco_vc
Senior Member
 
Join Date: Jan 2006
Location: Germany
Posts: 138
Thanks kichik for your answer. Can you also answer this one please: In the docu is not written but as my tests show the nsExec::Exec waits (always) for the run exe to finish. Is this assumption correct?

Thanks,
Viv
coco_vc is offline   Reply With Quote
Old 10th March 2006, 10:39   #5
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,337
Yes, nsExec always waits.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 10th March 2006, 12:11   #6
Red Wine
Forum King
 
Red Wine's Avatar
 
Join Date: Mar 2006
Location: Ath. GR
Posts: 2,078
I guess banner plug in is what you're looking for

Quick AVI Creator - Quick and easy convert from DVD/MPEG/AVI/MKV to AVI/MP4/MKV
Quick AVI Creator entirely edited with NSIS and entirely upgraded to Unicode NSIS
Red Wine is offline   Reply With Quote
Old 30th March 2006, 19:41   #7
Rodri
Junior Member
 
Join Date: Mar 2006
Posts: 4
I was trying to use nsExec for something similar:
I want to run the installation for the Java VM in my installer.

The thing is that the child process IS created, but then the setup for the JVM creates another process to continue the install, ending the original one.
I think that makes nsExec believe that the process which was monitoring ended (which is true).

How can I wait for the other process to finish before continuing with my installer?

Things I´ve tried:
- nsExec
- ExecCmd
- ExecDos
- Keep asking if I can delete the setup file in a loop
- Keep asking if the process is running in a loop

The last two are a bit (only a bit? ) unefficient (even with a "sleep" call) is there a more elegant solution?

Thanx for the answers.
Rodri is offline   Reply With Quote
Old 30th March 2006, 19:44   #8
Afrow UK
Moderator
 
Afrow UK's Avatar
 
Join Date: Nov 2002
Location: Birmingham, England
Posts: 8,203
What type of installer is it? InstallShield or?

-Stu

Need an installer? http://www.afrowsoft.co.uk
Afrow UK is offline   Reply With Quote
Old 30th March 2006, 19:48   #9
Rodri
Junior Member
 
Join Date: Mar 2006
Posts: 4
Quote:
Originally posted by Afrow UK
What type of installer is it? InstallShield or?

-Stu
Yeap, IShield

More things I´ve tried:
- Calling the setup from a bat
- The same with a "/wait" parameter
Rodri is offline   Reply With Quote
Old 31st March 2006, 00:00   #10
Red Wine
Forum King
 
Red Wine's Avatar
 
Join Date: Mar 2006
Location: Ath. GR
Posts: 2,078
Quote:
More things I´ve tried:
- Calling the setup from a bat
- The same with a "/wait" parameter
If it is IShield launch it from cmd with switch /H to see its options. Should be a switch to solve your problem.

Quick AVI Creator - Quick and easy convert from DVD/MPEG/AVI/MKV to AVI/MP4/MKV
Quick AVI Creator entirely edited with NSIS and entirely upgraded to Unicode NSIS
Red Wine is offline   Reply With Quote
Old 31st March 2006, 07:34   #11
Afrow UK
Moderator
 
Afrow UK's Avatar
 
Join Date: Nov 2002
Location: Birmingham, England
Posts: 8,203
Being that it is an InstallShield installer, your question/problem has been answered many times before...
http://forums.winamp.com/showthread....+installshield

-Stu

Need an installer? http://www.afrowsoft.co.uk
Afrow UK is offline   Reply With Quote
Old 31st March 2006, 09:18   #12
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,337
And even more specifically for Java:

http://java.sun.com/j2se/1.4.2/docs/...de/silent.html

Used "java silent install" on Google to find it as first result.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 31st March 2006, 15:25   #13
Rodri
Junior Member
 
Join Date: Mar 2006
Posts: 4
I´ve already tried the silent installation, but didn´t get what I´ve expected.

The useful stuff I got it from one of the threads you pointed, I´ve reached here

That one was perfect!

Thanx

Last edited by Rodri; 31st March 2006 at 17:33.
Rodri is offline   Reply With Quote
Old 31st March 2006, 15:29   #14
Afrow UK
Moderator
 
Afrow UK's Avatar
 
Join Date: Nov 2002
Location: Birmingham, England
Posts: 8,203
That link doesn't work.

-Stu

Need an installer? http://www.afrowsoft.co.uk
Afrow UK is offline   Reply With Quote
Old 31st March 2006, 17:34   #15
Rodri
Junior Member
 
Join Date: Mar 2006
Posts: 4
Fixed!
Rodri is offline   Reply With Quote
Old 2nd April 2006, 21:40   #16
JasonFriday13
Senior Member
 
JasonFriday13's Avatar
 
Join Date: May 2005
Location: Taranaki, New Zealand
Posts: 400
I was just trying to fix the same problem at the moment with one of my installers that runs IShield. Thanks guys.

"Only a MouseHelmet will save you from a MouseTrap" -Jason Ross (Me)
Wiki Profile
JasonFriday13 is offline   Reply With Quote
Reply
Go Back   Winamp Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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 Off

Forum Jump