Yzöwl Posted August 2, 2011 Share Posted August 2, 2011 This is how I'd expect it to read:REG ADD %KEY%\100 /V 1 /D "REG DELETE \"HKLM\Software\Microsoft\Windows NT\CurrentVersion\Print\Printers\,,ipp://dc2.mydomain.com,2F26P\" /F>NUL" /F>NUL Link to comment Share on other sites More sharing options...
Guest Posted August 3, 2011 Share Posted August 3, 2011 (edited) Also trying to add the following command to the RunOnce in the registry is this correct.REG ADD "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce\KickOff"="rundll32.exe iernonce.dll,RunOnceExProcess"STOP and READ THIS FIRST: The following code should not be necessary for RunOnceEX to start when Windows is restarted. RunOnceEX is automatically triggered when Windows starts.RunOnce works a bit differently. No subkeys are used, only values as shown below. RunOnce is triggered automatically when an INF file has finished installing/executing or at Windows start if it has not been run yet.REG ADD "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce" /V "KickOff" /D "rundll32.exe iernonce.dll,RunOnceExProcess" Edited August 3, 2011 by 5eraph Link to comment Share on other sites More sharing options...
clivebuckwheat Posted August 3, 2011 Author Share Posted August 3, 2011 Thanks I learn something new every day.I am trying to do the Adobe updates via reg addTo add this command with REG ADD start /wait C:\Applications\CS4\Updates\Soundbooth-2.0.1-786\Setup.exe\ --mode=silentREG ADD %KEY%\040 /VE /D "Installing Adobe CS4 Updates" /fREG ADD %KEY%\040 /V 1 /D "C:\Applications\CS4\Updates\Soundbooth-2.0.1-786\Setup.exe\ --mode=silent" /fI tried this but it ended way to fast, also would I need the start /wait with REG add? Link to comment Share on other sites More sharing options...
Yzöwl Posted August 3, 2011 Share Posted August 3, 2011 Using the method you suggested earlier in the Topic, does the following work?REG ADD %KEY%\020 /V 1 /D "\"C:\Applications\CS4\Setup.exe --mode=Silent --deploymentFile=\"C:\Applications\CS4\Adobe Creative Suite 4 Web Premium.install.xml\"\"" /F>NULThen with the Updates:REG ADD %KEY%\040 /V 1 /D "\"C:\Applications\CS4\Updates\Soundbooth-2.0.1-786\Setup.exe --mode=Silent\"" /F>NULAdditionally, since you don't appear to be installing using the console or a console based application then Start and Wait will make no difference to your installation. Link to comment Share on other sites More sharing options...
clivebuckwheat Posted August 4, 2011 Author Share Posted August 4, 2011 Does this look ok, because the updates are not installing, it skips over them way to fast.REG ADD %KEY%\040 /VE /D "Installing Adobe CS4 Updates" /fREG ADD %KEY%\040 /V 1 /D "\"C:\Applications\CS4\Updates\acrobat9pro-EFG\AcroProStdUpd910_T1T2_incr.msp\" /qn" /F>NULREG ADD %KEY%\040 /V 2 /D "\"C:\Applications\CS4\Updates\Updates\acrobat9pro-EFG\AcrobatUpd912_all_incr.msp\" /qn" /F>NUL REG ADD %KEY%\040 /V 3 /D "\"C:\Applications\CS4\Updates\Updates\acrobat9pro-EFG\AcrobatUpd920_all_incr.msp\" /qn" /F>NUL REG ADD %KEY%\040 /V 4 /D "\"C:\Applications\CS4\Updates\Fireworks-10.0.3-AdobeUpdate\Setup.exe --mode=silent\"" /F>NULREG ADD %KEY%\040 /V 5 /D "\"C:\Applications\CS4\Updates\Photoshop_11.0.2_mul_AdobeUpdate\Setup.exe --mode=silent\"" /F>NULREG ADD %KEY%\040 /V 6 /D "\"C:\Applications\CS4\Updates\AdobeDrive_1.0.1_AdobeUpdate_2\Setup.exe --mode=silent\"" /F>NULREG ADD %KEY%\040 /V 7 /D "\"C:\Applications\CS4\Updates\AdobeExtensionManager-2.1-mul-AdobeUpdate2\Setup.exe --mode=silent\"" /F>NULREG ADD %KEY%\040 /V 8 /D "\"C:\Applications\CS4\Updates\AdobeCameraRaw-5.7-mul-AdobeUpdate\Setup.exe --mode=silent\"" /F>NULREG ADD %KEY%\040 /V 9 /D "\"C:\Applications\CS4\Updates\AdobeOutputModule-2.1-mul-AdobeUpdate_2\Setup.exe --mode=silent\"" /F>NULREG ADD %KEY%\040 /V 10 /D "\"C:\Applications\CS4\Updates\AdobeVersionCue4All_4.0.1_AdobeUpdate_2\Setup.exe --mode=silent\"" /F>NULREG ADD %KEY%\040 /V 11 /D "\"C:\Applications\CS4\Updates\AME_All_CS4.2_mul_AdobeUpdate\Setup.exe --mode=silent\"" /F>NULREG ADD %KEY%\040 /V 12 /D "\"C:\Applications\CS4\Updates\DeviceCentral_2.1.1_mul_AdobeUpdate\Setup.exe --mode=silent\"" /F>NULREG ADD %KEY%\040 /V 13 /D "\"C:\Applications\CS4\Updates\Flash-10.0.2-AdobeUpdate\Setup.exe --mode=silent\"" /F>NULREG ADD %KEY%\040 /V 14 /D "\"C:\Applications\CS4\Updates\Soundbooth-2.0.1-786\Setup.exe --mode=Silent\"" /F>NUL Link to comment Share on other sites More sharing options...
Yzöwl Posted August 4, 2011 Share Posted August 4, 2011 Before you do anything else you need to ensure that the commands you want to run are in sequence, they will be run in sequence, not in the order you have written them.REG ADD %KEY%\040 /VE /D "Installing Adobe CS4 Updates" /fREG ADD %KEY%\040 /V 1REG ADD %KEY%\040 /V 10REG ADD %KEY%\040 /V 11REG ADD %KEY%\040 /V 12REG ADD %KEY%\040 /V 13REG ADD %KEY%\040 /V 14REG ADD %KEY%\040 /V 2REG ADD %KEY%\040 /V 3REG ADD %KEY%\040 /V 4REG ADD %KEY%\040 /V 5REG ADD %KEY%\040 /V 6REG ADD %KEY%\040 /V 7REG ADD %KEY%\040 /V 8REG ADD %KEY%\040 /V 9You need to change your values to include at least one leading zeroREG ADD %KEY%\040 /VE /D "Installing Adobe CS4 Updates" /fREG ADD %KEY%\040 /V 01REG ADD %KEY%\040 /V 02REG ADD %KEY%\040 /V 03REG ADD %KEY%\040 /V 04REG ADD %KEY%\040 /V 05REG ADD %KEY%\040 /V 06REG ADD %KEY%\040 /V 07REG ADD %KEY%\040 /V 08REG ADD %KEY%\040 /V 09REG ADD %KEY%\040 /V 10REG ADD %KEY%\040 /V 11REG ADD %KEY%\040 /V 12REG ADD %KEY%\040 /V 13REG ADD %KEY%\040 /V 14 Link to comment Share on other sites More sharing options...
clivebuckwheat Posted August 5, 2011 Author Share Posted August 5, 2011 Thanks. I didn't know I needed leading 0'sI have a question is there a way to check a range of computer names.For example if the computer name is 5B4-01 TO 5B15 DO thisOr would I need separate if statements for each pc? Link to comment Share on other sites More sharing options...
Guest Posted August 6, 2011 Share Posted August 6, 2011 (edited) It would be simpler to use separate IF statements.If there were a simple numeric progression to the computer names, such as 5B15 to 5B20, then it would be somewhat easy. The hyphen in the first name may add some complexity.But the progression as given escapes me. Can the hyphen and all characters that follow be ignored in the progression (to check 5B4 to 5B15, for example)?5B45B55B65B75B85B95B105B115B125B135B145B15The following code would check my example above:@ECHO OFFSETLOCAL EnableDelayedExpansion::Check the first two characters of %COMPUTERNAME%, if they do not match then skip the range check.::Otherwise, skip the first two verified characters and set a new variable to parse, then continue.IF /I "%COMPUTERNAME:~0,2%"=="5B" ( SET "COMPUTERNAME_TO_PARSE=%COMPUTERNAME:~2%" :: Remove hyphenated portion of %COMPUTERNAME%. FOR /F "tokens=1 delims=-" %%A IN ("!COMPUTERNAME_TO_PARSE!") DO (SET "COMPUTERNAME_TO_PARSE=%%A") :: Check numeric range from 4 to 15 with an increment of 1. FOR /L %%B IN (4,1,15) DO ( IF "!COMPUTERNAME_TO_PARSE!"=="%%B" ( COMMAND 1 GOES HERE COMMAND 2 GOES HERE COMMAND 3 GOES HERE COMMAND 4 GOES HERE COMMAND X GOES HERE...) ) ) Edited August 6, 2011 by 5eraph Link to comment Share on other sites More sharing options...
clivebuckwheat Posted August 6, 2011 Author Share Posted August 6, 2011 Thanks for your help on this I do appreciate it so much. Here's the thing. I have to install Adobe CS5 on 15 computers. The standard naming convention we use is 5b4-01 5b4-02 etc. I wish we could ditch the hyphen but I can't. Thanks for all your help again. Link to comment Share on other sites More sharing options...
bphlpt Posted August 6, 2011 Share Posted August 6, 2011 (edited) So your list of computers is NOT5B4-01 TO 5B15But should be5B4-01 TO 5B4-15???If so, then it should be VERY simple to modify 5eraph's script accordingly, ieCheck the first FOUR characters of %COMPUTERNAME%, if they are NOT "5B4-" then exit, and if so separate the next two characters into a variable and check to see if they are in the range you require. If not, then exit, and if so continue your install.Cheers and Regards Edited August 6, 2011 by bphlpt Link to comment Share on other sites More sharing options...
clivebuckwheat Posted August 6, 2011 Author Share Posted August 6, 2011 So sorry yes 5B4-01 TO 5B4-15. I made a typo I apologize. Link to comment Share on other sites More sharing options...
Guest Posted August 6, 2011 Share Posted August 6, 2011 Correct, bphlpt. We just need to add a leading zero if necessary.Here's the new code to check 5B4-01 through 5B4-15:@ECHO OFFSETLOCAL EnableDelayedExpansion::Check the first four characters of %COMPUTERNAME%, if they do not match then skip the range check.::Otherwise, skip the first four verified characters and set a new variable to parse, then continue.IF /I "%COMPUTERNAME:~0,4%"=="5B4-" ( SET "COMPUTERNAME_TO_PARSE=%COMPUTERNAME:~4%" :: Check numeric range from 1 to 15 with an increment of 1, add leading zero if necessary. FOR /L %%B IN (1,1,15) DO ( IF %%B LSS 10 (SET "LEADING_ZERO=0") ELSE (SET "LEADING_ZERO=") IF "!COMPUTERNAME_TO_PARSE!"=="!LEADING_ZERO!%%B" ( COMMAND 1 GOES HERE COMMAND 2 GOES HERE COMMAND 3 GOES HERE COMMAND 4 GOES HERE COMMAND X GOES HERE...) ) ) Link to comment Share on other sites More sharing options...
clivebuckwheat Posted August 6, 2011 Author Share Posted August 6, 2011 (edited) I have learned a lot this week from you guys. I know how to do this, check the first FOUR characters of %COMPUTERNAME%, if they are NOT "5B4- then exit. Not quite sure how to doand if so separate the next two characters into a variable and check to see if they are in the range you require -this yetBut I will trySo your list of computers is NOT5B4-01 TO 5B15But should be5B4-01 TO 5B4-15???If so, then it should be VERY simple to modify 5eraph's script accordingly, ieCheck the first FOUR characters of %COMPUTERNAME%, if they are NOT "5B4-" then exit, and if so separate the next two characters into a variable and check to see if they are in the range you require. If not, then exit, and if so continue your install.Cheers and Regards Edited August 6, 2011 by clivebuckwheat Link to comment Share on other sites More sharing options...
Guest Posted August 6, 2011 Share Posted August 6, 2011 Scroll up for a revised script, clivebuckwheat. Link to comment Share on other sites More sharing options...
bphlpt Posted August 6, 2011 Share Posted August 6, 2011 (edited) 5eraph has provided the code for you above.EDIT: heheh - Seraph reposted while I was editing Cheers and Regards Edited August 6, 2011 by bphlpt Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now