I need some help setting up a script for writing a text to a specific file.

I want this text:
<?xml version="1.0" encoding="UTF-8" ?>
- <AdobeUpdater>
<DownloadDir>C:\Program Files\Adobe\Updater</DownloadDir>
- <ApplicationsEnabled>
<MapPrefEntry MapPrefKey="bridge1">0</MapPrefEntry>
<MapPrefEntry MapPrefKey="creativesuite2-en_US">0</MapPrefEntry>
<MapPrefEntry MapPrefKey="golive8-en_US-LIC">0</MapPrefEntry>
<MapPrefEntry MapPrefKey="helpcenter1">0</MapPrefEntry>
<MapPrefEntry MapPrefKey="illustrator12-en_inatl-LIC">0</MapPrefEntry>
<MapPrefEntry MapPrefKey="indesign4-en_GB-NONDEBUG,LIC">0</MapPrefEntry>
<MapPrefEntry MapPrefKey="photoshop9-en_US-LIC">0</MapPrefEntry>
<MapPrefEntry MapPrefKey="stockphotos1">0</MapPrefEntry>
<MapPrefEntry MapPrefKey="versioncue2-en_US-CS">0</MapPrefEntry>

In this file:

This is a script wich is supposed to run on first login for users in AD.

Thanks in advance.

- Robert Hagen
0 Comments   [ - ] Hide Comments


Please log in to comment

Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
Answer this question or Comment on this question for clarity


Why use a script when you just can copy the "new" file to the location through a logon script?
Answered 08/08/2005 by: AngelD
Red Belt

Please log in to comment
Since this forum relates to MSI, here's an "MSI" answer...

1) Copy the file with a (per-machine) msi package - under the "AppDataFolder" directory.

2) Include an "HKCU" registry key (make one up) within the same component and make this key the "keypath" for the component.

3) Include an empty vbscript file within the same feature (maybe in the INSTALLDIR folder) with an advertised shortcut in the "StartUpFolder" directory.

Everytime a user logs on the advertised VBScript will run (it will do nothing because it's empty) but all components within the same feature will first be checked by the shell before it is executed. If the "HKCU" key is not there (first time), the component will be deemed "broken" and will therefore be repaired (including your file).

Remember that the original MSI source must be available at all times for this to work. Although there is a "trick" that can be used to avoid this (using a duplicate file).

It is even possible to remove the cancel button from the resulting repair progress dialog, or even to hide it altogether.
Answered 08/09/2005 by: WiseUser
Fourth Degree Brown Belt

Please log in to comment
Okay i put together a little command to do it which i put in a cmd file.

The command is the following:
xcopy "\\server\share\AdobeUpdaterPrefs.dat" "%appdata%\Adobe\Updater\" /K /Y /R /Q

But the cmd file wich i have gpo loading on logon for users wont start...

Any ideas why it wont run the cmd file on logon?

- Robert
Answered 08/09/2005 by: babaloui
Yellow Belt

Please log in to comment