MSFN Forum: Pause or Wait command/switch for RunOnceEx.cmd - MSFN Forum

Jump to content



Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Pause or Wait command/switch for RunOnceEx.cmd Rate Topic: -----

#1 User is offline   Dr3amW3av3r 

  • Group: Members
  • Posts: 5
  • Joined: 27-December 05

  Posted 03 January 2006 - 10:00 PM

Hello all,

Currently I am designing my unattended install and am using the RunOnceEx.cmd method to install apps.

Is there a way to tell runonceex.cmd to wait for say 60 secs before it goes onto install the next piece of software?

The reason is, I have Java VM starting to install AFTER Microsoft .NET Infrastructure.
Now I am assuming that runonceex.cmd thinks that the program install for .NET has finished and starts to execute the install for Java, but then I get a message on the screen saying

"Another application is still installing, please wait for it to finish"

Is there a way to let >NET finish what ever it is doing in the back ground before the install of Java starts?

thanks very much for your help.


#2 User is offline   MHz 

  • SendToA3X v1.7
  • PipPipPipPipPipPipPip
  • Group: Members
  • Posts: 1,634
  • Joined: 02-August 04

Posted 03 January 2006 - 10:19 PM

Welcome to MSFN,
It would be helpful to know what commands you are using for these 2 installations. I do not think a 60 secs of wait is needed.

#3 User is offline   gunsmokingman 

  • MSFN Master
  • Group: Super Moderator
  • Posts: 2,020
  • Joined: 02-August 03
  • OS:none specified
  • Country: Country Flag

Posted 03 January 2006 - 10:48 PM

Do you have this to start your cmd, this tell it to start then wait for whatever to be finished.

Quote

Start /Wait What_Ever_Drive:\What_Ever_Location\What_Ever.exe
or
Start /W What_Ever_Drive:\What_Ever_Location\What_Ever.exe


If you want something just to pause then restart after X amount of time
red text is the amount of time the script pauses for

Quote

ping -n 60 127.0.0.1>nul


#4 User is offline   Dr3amW3av3r 

  • Group: Members
  • Posts: 5
  • Joined: 27-December 05

Posted 03 January 2006 - 11:02 PM

View PostMHz, on Jan 4 2006, 03:19 PM, said:

Welcome to MSFN,
It would be helpful to know what commands you are using for these 2 installations. I do not think a 60 secs of wait is needed.


Here are the lines of code in my RunOnceEx.cmd file:

cmdow @ /HID
@echo off

FOR %%i IN (D E F G H I J K L M N O P Q R S T U V W X Y Z) DO IF EXIST %%i:\CD.txt SET CDROM=%%i:

SET KEY=HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnceEx

REG ADD %KEY% /V TITLE /D "Installing Applications" /f

REG ADD %KEY%\005 /VE /D "Adobe Reader 7" /f
REG ADD %KEY%\005 /V 1 /D "%CDROM%\Software\AdobeReader7\AR7.exe /S /v/qn" /f

REG ADD %KEY%\037 /VE /D "IsoBuster 1.9" /f
REG ADD %KEY%\037 /V 1 /D "%CDROM%\Software\IsoBuster19.exe /VERYSILENT /SP-" /f
REG ADD %KEY%\037 /V 2 /D "taskkill /F /IM isobuster.exe" /f

REG ADD %KEY%\053 /VE /D ".NET Framework 1.1" /f
REG ADD %KEY%\053 /V 1 /D "%CDROM%\Software\dotnet\dotnetinstall.exe" /f

REG ADD %KEY%\065 /VE /D "Sun Java 1.4.2" /f
REG ADD %KEY%\065 /V 1 /D "%CDROM%\Software\jre-1_5_0_04-windows-i586-p.exe /s /v/qn" /f
REG ADD %KEY%\065 /V 2 /D "REGEDIT /S %CDROM%\Software\RemoveSunJavaUpdateCheck.reg" /f

REG ADD %KEY%\075 /VE /D "WinRAR 3.51" /f
REG ADD %KEY%\075 /V 1 /D "%CDROM%\Software\Wrar351.exe /s" /f

REG ADD %KEY%\080 /VE /D "Installing Office 2003" /f
REG ADD %KEY%\080 /V 1 /D "%CDROM%\Software\Office2003\setuppro.exe TRANSFORMS=Unattended.MST /qb-" /f

REG ADD %KEY%\085 /VE /D "Adding Users" /f
REG ADD %KEY%\085 /V 1 /D "%CDROM%\Software\useraccounts.cmd" /f

REG ADD %KEY%\090 /VE /D "Installing Various Media Codecs" /f
REG ADD %KEY%\090 /V 1 /D "%CDROM%\Software\codecs.cmd" /f

REG ADD %KEY%\150 /VE /D "Cleaning Up and Rebooting" /f
REG ADD %KEY%\150 /V 1 /D "%CDROM%\Software\cleanup.cmd" /f

EXIT

#5 User is offline   Dr3amW3av3r 

  • Group: Members
  • Posts: 5
  • Joined: 27-December 05

Posted 03 January 2006 - 11:29 PM

View Postgunsmokingman, on Jan 4 2006, 02:48 PM, said:

Do you have this to start your cmd, this tell it to start then wait for whatever to be finished.

Quote

Start /Wait What_Ever_Drive:\What_Ever_Location\What_Ever.exe
or
Start /W What_Ever_Drive:\What_Ever_Location\What_Ever.exe


If you want something just to pause then restart after X amount of time
red text is the amount of time the script pauses for

Quote

ping -n 60 127.0.0.1>nul




Hi there,

So where does this exactly go in the RunOnceEx.cmd file?

#6 User is offline   MHz 

  • SendToA3X v1.7
  • PipPipPipPipPipPipPip
  • Group: Members
  • Posts: 1,634
  • Joined: 02-August 04

Posted 03 January 2006 - 11:49 PM

Quote

REG ADD %KEY%\053 /VE /D ".NET Framework 1.1" /f
REG ADD %KEY%\053 /V 1 /D "%CDROM%\Software\dotnet\dotnetinstall.exe" /f

REG ADD %KEY%\065 /VE /D "Sun Java 1.4.2" /f
REG ADD %KEY%\065 /V 1 /D "%CDROM%\Software\jre-1_5_0_04-windows-i586-p.exe /s /v/qn" /f
REG ADD %KEY%\065 /V 2 /D "REGEDIT /S %CDROM%\Software\RemoveSunJavaUpdateCheck.reg" /f

REG ADD %KEY%\075 /VE /D "WinRAR 3.51" /f
REG ADD %KEY%\075 /V 1 /D "%CDROM%\Software\Wrar351.exe /s" /f

No switches are shown for .Net Framework.
Since you have WinRAR in your list, I could assume you have repacked .Net with also patched with SP1. Below is the comment I used for my WinRAR SFX. RunOnceEx does wait for the end of installation
;The comment below contains SFX script commands

Setup=Netfx.msi /qb /norestart
TempMode
Silent=2
Overwrite=1


If you want to use GSM's idea then it would look like below:
REG ADD %KEY%\053 /VE /D ".NET Framework 1.1" /f
REG ADD %KEY%\053 /V 1 /D "%CDROM%\Software\dotnet\dotnetinstall.exe" /f
REG ADD %KEY%\053 /V 2 /D "ping -n 60 127.0.0.1>nul" /f

REG ADD %KEY%\065 /VE /D "Sun Java 1.4.2" /f
REG ADD %KEY%\065 /V 1 /D "%CDROM%\Software\jre-1_5_0_04-windows-i586-p.exe /s /v/qn" /f
REG ADD %KEY%\065 /V 2 /D "REGEDIT /S %CDROM%\Software\RemoveSunJavaUpdateCheck.reg" /f


#7 User is offline   Dr3amW3av3r 

  • Group: Members
  • Posts: 5
  • Joined: 27-December 05

Posted 04 January 2006 - 12:02 AM

If you want to use GSM's idea then it would look like below:
REG ADD %KEY%\053 /VE /D ".NET Framework 1.1" /f
REG ADD %KEY%\053 /V 1 /D "%CDROM%\Software\dotnet\dotnetinstall.exe" /f
REG ADD %KEY%\053 /V 2 /D "ping -n 60 127.0.0.1>nul" /f

REG ADD %KEY%\065 /VE /D "Sun Java 1.4.2" /f
REG ADD %KEY%\065 /V 1 /D "%CDROM%\Software\jre-1_5_0_04-windows-i586-p.exe /s /v/qn" /f
REG ADD %KEY%\065 /V 2 /D "REGEDIT /S %CDROM%\Software\RemoveSunJavaUpdateCheck.reg" /f

[/quote]


Hello MHz thank you very much for this pointer and I shall try it out....

#8 User is offline   ProClub 

  • Newbie
  • Group: Members
  • Posts: 25
  • Joined: 30-April 05

Posted 09 January 2006 - 03:32 AM

There is a sleep utility. However, it would be much better, if there was a way to use start /wait from runonceex.

#9 User is offline   MHz 

  • SendToA3X v1.7
  • PipPipPipPipPipPipPip
  • Group: Members
  • Posts: 1,634
  • Joined: 02-August 04

Posted 09 January 2006 - 04:12 AM

View PostProClub, on Jan 9 2006, 07:32 PM, said:

There is a sleep utility. However, it would be much better, if there was a way to use start /wait from runonceex.

RunOnceEx does wait.

#10 User is offline   RickSteele 

  • Rick Steele
  • PipPip
  • Group: Members
  • Posts: 259
  • Joined: 13-October 04
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 14 May 2007 - 04:43 PM

View PostMHz, on Jan 9 2006, 04:12 AM, said:

View PostProClub, on Jan 9 2006, 07:32 PM, said:

There is a sleep utility. However, it would be much better, if there was a way to use start /wait from runonceex.

RunOnceEx does wait.

It did not for me. It was like when the WAIT switch has no effect in a batch file-which it seldom does- and all your executables run simultaneously to the point where finally the system finishes booting into windows with all of these setup prompts tiled on the desktop; what a mess! :wacko:

I was wandering if, aside from the "REG ADD %KEY%53 /V 2 /D "ping -n 60 127.0.0.1>nul" /f" solution, there is a "pause" instruction that stops the cmd's progress until "any key is pressed" type thing; similar to "pause" in a batch file?

This post has been edited by RickSteele: 14 May 2007 - 04:53 PM


#11 User is offline   Greenhorn 

  • Group: Members
  • Posts: 8
  • Joined: 06-September 07

Posted 08 September 2007 - 01:34 PM

View PostMHz, on Jan 3 2006, 11:49 PM, said:

Since you have WinRAR in your list, I could assume you have repacked .Net with also patched with SP1. Below is the comment I used for my WinRAR SFX. RunOnceEx does wait for the end of installation
;The comment below contains SFX script commands
   
   Setup=Netfx.msi /qb /norestart
   TempMode
   Silent=2
   Overwrite=1


Hi there,

you should use the introdution from MHz !
It's the easiest way to solve the problem. :thumbup

Here the Option for .NET 2 and 3
Setup=install.exe /q
 TempMode
 Silent=1
 Overwrite=1



Greetz
Greenhorn

#12 User is offline   thedexmonster 

  • Newbie
  • Group: Members
  • Posts: 18
  • Joined: 19-September 07

Posted 30 September 2007 - 02:07 AM

View PostRickSteele, on May 14 2007, 03:43 PM, said:

View PostMHz, on Jan 9 2006, 04:12 AM, said:

View PostProClub, on Jan 9 2006, 07:32 PM, said:

There is a sleep utility. However, it would be much better, if there was a way to use start /wait from runonceex.

RunOnceEx does wait.

It did not for me. It was like when the WAIT switch has no effect in a batch file-which it seldom does- and all your executables run simultaneously to the point where finally the system finishes booting into windows with all of these setup prompts tiled on the desktop; what a mess! :wacko:

I was wandering if, aside from the "REG ADD %KEY%53 /V 2 /D "ping -n 60 127.0.0.1>nul" /f" solution, there is a "pause" instruction that stops the cmd's progress until "any key is pressed" type thing; similar to "pause" in a batch file?


It's probably too late now, but all you have to do is call a batch file with PAUSE written in it from runonceex.cmd.

"REG ADD %KEY%53 /VE /D "Wait for ... to finish" /f"
"REG ADD %KEY%53 /V 1 /D "%systemdrive%\install\pause.cmd" /f"
pause.cmd consisting of purely PAUSE

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users



All trademarks mentioned on this page are the property of their respective owners
Copyright © 2001 - 2011 msfn.org
Privacy Policy