Jump to content
Strawberry Orange Banana Lime Leaf Slate Sky Blueberry Grape Watermelon Chocolate Marble
Strawberry Orange Banana Lime Leaf Slate Sky Blueberry Grape Watermelon Chocolate Marble

MSFN is made available via donations, subscriptions and advertising revenue. The use of ad-blocking software hurts the site. Please disable ad-blocking software or set an exception for MSFN. Alternatively, register and become a site sponsor/subscriber and ads will be disabled automatically. 


Sign in to follow this  
clivebuckwheat

Tell me what is wrong with this. REG ADD ERROR

Recommended Posts

Thank you guys.

Last task for me this week is to do an unattended install of Dreamweaver and photoshop from CS3 with the updates that task is for tomorrow . The struggle continues, but I have learned so much. Thank you for all your time and effort guys. Classes start in a week and I am under the gun to piece it all together.

I have another issue.

My Adobe unattended cs4 install works fine.

When I call the updates from a batch file they work fine.

when I call it with like this it works

REG ADD %KEY%\040 /VE /D "Installing Adobe CS4 Updates" /f

REG ADD %KEY%\040 /V 1 /D "C:\Applications\CS4\CS4Updates.cmd" /f

CS4Updates.cmd

start /wait C:\Applications\CS4\Updates\acrobat9pro-EFG\AcroProStdUpd910_T1T2_incr.msp\ /qn
start /wait C:\Applications\CS4\Updates\acrobat9pro-EFG\AcrobatUpd912_all_incr.msp\ /qn
start /wait C:\Applications\CS4\Updates\acrobat9pro-EFG\AcrobatUpd920_all_incr.msp\ /qn
start /wait C:\Applications\CS4\Updates\Fireworks-10.0.3-AdobeUpdate\Setup.exe\ --mode=silent
start /wait C:\Applications\CS4\Updates\Photoshop_11.0.2_mul_AdobeUpdate\Setup.exe\ --mode=silent
start /wait C:\Applications\CS4\Updates\AdobeDrive_1.0.1_AdobeUpdate_2\Setup.exe\ --mode=silent
start /wait C:\Applications\CS4\Updates\AdobeExtensionManager-2.1-mul-AdobeUpdate2\Setup.exe\ --mode=silent
start /wait C:\Applications\CS4\Updates\AdobeCameraRaw-5.7-mul-AdobeUpdate\Setup.exe\ --mode=silent
start /wait C:\Applications\CS4\Updates\AdobeOutputModule-2.1-mul-AdobeUpdate_2\Setup.exe\ --mode=silent
start /wait C:\Applications\CS4\Updates\AdobeVersionCue4All_4.0.1_AdobeUpdate_2\Setup.exe\ --mode=silent
start /wait C:\Applications\CS4\Updates\AME_All_CS4.2_mul_AdobeUpdate\Setup.exe\ --mode=silent
start /wait C:\Applications\CS4\Updates\DeviceCentral_2.1.1_mul_AdobeUpdate\Setup.exe\ --mode=silent
start /wait C:\Applications\CS4\Updates\Flash-10.0.2-AdobeUpdate\Setup.exe\ --mode=silent
start /wait C:\Applications\CS4\Updates\Soundbooth-2.0.1-786\Setup.exe\ --mode=silent

IF I call it like this the updates do not install.

REG ADD %KEY%\040 /VE /D "Installing Adobe CS4 Updates" /f
REG ADD %KEY%\040 /V 01 /D "\"C:\Applications\CS4\Updates\acrobat9pro-EFG\AcroProStdUpd910_T1T2_incr.msp\" /qn" /F>NUL
REG ADD %KEY%\040 /V 02 /D "\"C:\Applications\CS4\Updates\Updates\acrobat9pro-EFG\AcrobatUpd912_all_incr.msp\" /qn" /F>NUL
REG ADD %KEY%\040 /V 03 /D "\"C:\Applications\CS4\Updates\Updates\acrobat9pro-EFG\AcrobatUpd920_all_incr.msp\" /qn" /F>NUL
REG ADD %KEY%\040 /V 04 /D "\"C:\Applications\CS4\Updates\Fireworks-10.0.3-AdobeUpdate\Setup.exe --mode=silent\"" /F>NUL
REG ADD %KEY%\040 /V 05 /D "\"C:\Applications\CS4\Updates\Photoshop_11.0.2_mul_AdobeUpdate\Setup.exe --mode=silent\"" /F>NUL
REG ADD %KEY%\040 /V 06 /D "\"C:\Applications\CS4\Updates\AdobeDrive_1.0.1_AdobeUpdate_2\Setup.exe --mode=silent\"" /F>NUL
REG ADD %KEY%\040 /V 07 /D "\"C:\Applications\CS4\Updates\AdobeExtensionManager-2.1-mul-AdobeUpdate2\Setup.exe --mode=silent\"" /F>NUL
REG ADD %KEY%\040 /V 08 /D "\"C:\Applications\CS4\Updates\AdobeCameraRaw-5.7-mul-AdobeUpdate\Setup.exe --mode=silent\"" /F>NUL
REG ADD %KEY%\040 /V 09 /D "\"C:\Applications\CS4\Updates\AdobeOutputModule-2.1-mul-AdobeUpdate_2\Setup.exe --mode=silent\"" /F>NUL
REG ADD %KEY%\040 /V 10 /D "\"C:\Applications\CS4\Updates\AdobeVersionCue4All_4.0.1_AdobeUpdate_2\Setup.exe --mode=silent\"" /F>NUL
REG ADD %KEY%\040 /V 11 /D "\"C:\Applications\CS4\Updates\AME_All_CS4.2_mul_AdobeUpdate\Setup.exe --mode=silent\"" /F>NUL
REG ADD %KEY%\040 /V 12 /D "\"C:\Applications\CS4\Updates\DeviceCentral_2.1.1_mul_AdobeUpdate\Setup.exe --mode=silent\"" /F>NUL
REG ADD %KEY%\040 /V 13 /D "\"C:\Applications\CS4\Updates\Flash-10.0.2-AdobeUpdate\Setup.exe --mode=silent\"" /F>NUL
REG ADD %KEY%\040 /V 14 /D "\"C:\Applications\CS4\Updates\Soundbooth-2.0.1-786\Setup.exe --mode=Silent\"" /F>NUL

Edited by clivebuckwheat

Share this post


Link to post
Share on other sites

If you where to use VBS scripting then a script to do what you want would look like this


Dim Act :Set Act = CreateObject("Wscript.Shell")

Dim Arg, AdobePath, AdobeFile, C1, Key, Obj, Var
AdobePath = "C:\Applications\CS4\Updates\"
Arg = " --mode=silent"
AdobeFile = Array( _
AdobePath & "acrobat9pro-EFG\AcroProStdUpd910_T1T2_incr.msp <> /qn", _
AdobePath & "acrobat9pro-EFG\AcrobatUpd912_all_incr.msp <> /qn", _
AdobePath & "acrobat9pro-EFG\AcrobatUpd920_all_incr.msp <> /qn", _
AdobePath & "Fireworks-10.0.3-AdobeUpdate\Setup.exe <> " & Arg, _
AdobePath & "Photoshop_11.0.2_mul_AdobeUpdate\Setup.exe <> " & Arg, _
AdobePath & "AdobeDrive_1.0.1_AdobeUpdate_2\Setup.exe <> " & Arg, _
AdobePath & "AdobeExtensionManager-2.1-mul-AdobeUpdate2\Setup.exe <> " & Arg, _
AdobePath & "AdobeCameraRaw-5.7-mul-AdobeUpdate\Setup.exe <> " & Arg, _
AdobePath & "AdobeOutputModule-2.1-mul-AdobeUpdate_2\Setup.exe <> " & Arg, _
AdobePath & "AdobeVersionCue4All_4.0.1_AdobeUpdate_2\Setup.exe <> " & Arg, _
AdobePath & "AME_All_CS4.2_mul_AdobeUpdate\Setup.exe <> " & Arg, _
AdobePath & "DeviceCentral_2.1.1_mul_AdobeUpdate\Setup.exe <> " & Arg, _
AdobePath & "Flash-10.0.2-AdobeUpdate\Setup.exe <> " & Arg, _
AdobePath & "Soundbooth-2.0.1-786\Setup.exe <> " & Arg)
C1 = 1
Key = "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnceEx\"
Act.RegWrite Key & "040\", "Installing Adobe CS4 Updates", "REG_SZ"
For Each Obj In AdobeFile
Var = Split(Obj," <> ")
Act.RegWrite Key & "040\" & C1, Chr(34) & Var(0) & Chr(34) & Var(1), "REG_SZ"
C1 = C1 + 1
Next

Share this post


Link to post
Share on other sites

Thank you. It works great.

After my install of Adobe CS4 I noticed that Adobe reader X is no longer the default PDF application, but Adobe Reader pro is, is there any way to change it back via batch mode so that Adobe Reader X is the default.

Again thanks for all your help.

Share this post


Link to post
Share on other sites

Have you tried installing the CS4 stuff before installing the Reader?

Share this post


Link to post
Share on other sites

Thank you. It works great.

After my install of Adobe CS4 I noticed that Adobe reader X is no longer the default PDF application, but Adobe Reader pro is, is there any way to change it back via batch mode so that Adobe Reader X is the default.

Again thanks for all your help.

Have you tried batch command assoc? Already suggest to you over here.

Edit: Add Assoc ref link

Edited by Geej

Share this post


Link to post
Share on other sites

I have tried the assoc command, but it didn't work for me, maybe I did it wrong.

I am trying to change the associate from Acrobat pro 9 back to Reader X. I am going to try again

Share this post


Link to post
Share on other sites

I tried on my XP in VM for Adobe Reader X, then install foxit reader. Take some data to check before putting association back to Adobe Reader X

Try this on PC that has Adobe Reader X set as default. To generate a current list of association before CS4 installation.

@echo off
set viewfile=ARX5.txt
assoc .pdf>%viewfile%
Echo=>>%viewfile%
assoc>>%viewfile%
Start "view now" %viewfile%

You will see .pdf=AcroExch.Document is the present association (line 1 of ARX5.txt). This is Adobe Reader X association.

Do a text search for 'AcroExch.' within ARX5.txt, you will also notice there are some other file extension associate with Reader X. They are

.acrobatsecuritysettings=AcroExch.acrobatsecuritysettings
.api=AcroExch.Plugin
.fdf=AcroExch.FDFDoc
.pdf=AcroExch.Document
.pdfxml=AcroExch.pdfxml
.secstore=AcroExch.SecStore
.xdp=AcroExch.XDPDoc
.xfdf=AcroExch.XFDFDoc

In my humble view , only .pdf & .fdf are necessary. But here you are the judge.

Then proceed to install CS4. After that generate another list as your new file association inventory. Do a comparsion to observe the difference.

@echo off
set viewfile=APro9.txt
assoc .pdf>%viewfile%
Echo=>>%viewfile%
assoc>>%viewfile%
Start "view now" %viewfile%

Now to set it back to Adobe Reader X as default, run this batch command

@echo off
assoc .pdf=AcroExch.Document
assoc .fdf=AcroExch.FDFDoc

Done. Just test by opening a pdf file directly. Hope this helps.

Share this post


Link to post
Share on other sites

I spoke to soon after tried the above association and after the cs4 install pro was still the default after running the batch.

@echo off
assoc .pdf=AcroExch.Document
assoc .fdf=AcroExch.FDFDoc

Edited by clivebuckwheat

Share this post


Link to post
Share on other sites

Can this line use the /f

REG ADD HKLM\SOFTWARE\MICROSOFT\WINDOWS\CURRENTVERSION\RunOnceEx

I'd like to force it to overwritten if it already exists, I am in the testing phase at the moment of my scripts

Share this post


Link to post
Share on other sites

Why do you need to overwrite a key name which already exists?

You should only need to overwrite data contained within a key, not the name of the key.

Are you hoping to empty all data contained within the tree below that key, if so try it on a live system. If it doesn't work then simply use REG DELETE followed by REG ADD.

Share this post


Link to post
Share on other sites

I spoke to soon after tried the above association and after the cs4 install pro was still the default after running the batch.

@echo off
assoc .pdf=AcroExch.Document
assoc .fdf=AcroExch.FDFDoc

Perhaps when you apply the above batch, it set association to your host pc, not your client PC.

Try adding the command to the registry instead. Something like (in key 20 I suggested)

@echo off
Set key=HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnceEx
REG ADD %KEY%\040 /VE /D "Installing Adobe CS4 Updates" /f
REG ADD %KEY%\040 /V 01 /D "\"C:\Applications\CS4\Updates\acrobat9pro-EFG\AcroProStdUpd910_T1T2_incr.msp\" /qn" /F>NUL
REG ADD %KEY%\040 /V 02 /D "\"C:\Applications\CS4\Updates\Updates\acrobat9pro-EFG\AcrobatUpd912_all_incr.msp\" /qn" /F>NUL
REG ADD %KEY%\040 /V 03 /D "\"C:\Applications\CS4\Updates\Updates\acrobat9pro-EFG\AcrobatUpd920_all_incr.msp\" /qn" /F>NUL
REG ADD %KEY%\040 /V 04 /D "\"C:\Applications\CS4\Updates\Fireworks-10.0.3-AdobeUpdate\Setup.exe --mode=silent\"" /F>NUL
REG ADD %KEY%\040 /V 05 /D "\"C:\Applications\CS4\Updates\Photoshop_11.0.2_mul_AdobeUpdate\Setup.exe --mode=silent\"" /F>NUL
REG ADD %KEY%\040 /V 06 /D "\"C:\Applications\CS4\Updates\AdobeDrive_1.0.1_AdobeUpdate_2\Setup.exe --mode=silent\"" /F>NUL
REG ADD %KEY%\040 /V 07 /D "\"C:\Applications\CS4\Updates\AdobeExtensionManager-2.1-mul-AdobeUpdate2\Setup.exe --mode=silent\"" /F>NUL
REG ADD %KEY%\040 /V 08 /D "\"C:\Applications\CS4\Updates\AdobeCameraRaw-5.7-mul-AdobeUpdate\Setup.exe --mode=silent\"" /F>NUL
REG ADD %KEY%\040 /V 09 /D "\"C:\Applications\CS4\Updates\AdobeOutputModule-2.1-mul-AdobeUpdate_2\Setup.exe --mode=silent\"" /F>NUL
REG ADD %KEY%\040 /V 10 /D "\"C:\Applications\CS4\Updates\AdobeVersionCue4All_4.0.1_AdobeUpdate_2\Setup.exe --mode=silent\"" /F>NUL
REG ADD %KEY%\040 /V 11 /D "\"C:\Applications\CS4\Updates\AME_All_CS4.2_mul_AdobeUpdate\Setup.exe --mode=silent\"" /F>NUL
REG ADD %KEY%\040 /V 12 /D "\"C:\Applications\CS4\Updates\DeviceCentral_2.1.1_mul_AdobeUpdate\Setup.exe --mode=silent\"" /F>NUL
REG ADD %KEY%\040 /V 13 /D "\"C:\Applications\CS4\Updates\Flash-10.0.2-AdobeUpdate\Setup.exe --mode=silent\"" /F>NUL
REG ADD %KEY%\040 /V 14 /D "\"C:\Applications\CS4\Updates\Soundbooth-2.0.1-786\Setup.exe --mode=Silent\"" /F>NUL
REG ADD %KEY%\040 /V 20 /D "\"cmd /c assoc .pdf=AcroExch.Document\"" /F>NUL

Suggest you let us know what key you are prompt to give Yes/No reply as asked by Yzöwl. Or post the full script for us to get a better picture?

Or temporary remove >NUL from your batch file so that you can see what error message you encounter during run.

Edit: Add

Wait clivebuckweat. On 2nd thought

pls check whether .pdf return same sting (.pdf=AcroExch.Document) after cs4 is installed.

If they are the same then using assoc will not make any different. Need to go to registry to change path to Reader X.

Try changing the program path in

HKEY_LOCAL_MACHINE\SOFTWARE\Classes\AcroExch.Document\Shell\Open\Command

Edited by Geej

Share this post


Link to post
Share on other sites
Suggest you let us know what key you are prompt to give Yes/No reply as asked by Yzöwl. Or post the full script for us to get a better picture?

Or temporary remove >NUL from your batch file so that you can see what error message you encounter during run.

This is the line I am prompted for YES/NO. When I re-run my script a second time.

REG ADD HKLM\SOFTWARE\MICROSOFT\WINDOWS\CURRENTVERSION\RunOnceEx

For my PDF woes reader not being the default after cs4 has been installed.

Edit: Add

Wait clivebuckweat. On 2nd thought

pls check whether .pdf return same sting (.pdf=AcroExch.Document) after cs4 is installed.

If they are the same then using assoc will not make any different. Need to go to registry to change path to Reader X.

Try changing the program path in

HKEY_LOCAL_MACHINE\SOFTWARE\Classes\AcroExch.Document\Shell\Open\Command

after the CS4 installation the association is exactly the same as it was with reader x

(.pdf=AcroExch.Document)

I tried this to change the default pdf back to reader X it did not work.

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\AcroExch.Document\Shell\Open\Command]
@="\"C:\\Program Files (x86)\\Adobe\\Reader 10.0\\Reader\\AcroRd32.exe\" \"%1\""

UPDATE! This fixed it.

Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts\.pdf\UserChoice]
"Progid"="Applications\\AcroRd32.exe"

Edited by clivebuckwheat

Share this post


Link to post
Share on other sites
This is the line I am prompted for YES/NO. When I re-run my script a second time.

REG ADD HKLM\SOFTWARE\MICROSOFT\WINDOWS\CURRENTVERSION\RunOnceEx

That line shouldn't be there, the key already exists, you do not need to add it or overwrite it, your entire script should only be adding sub-keys and sub-key data beneath that level.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...