David,
Not sure why it isn't working. I have had oWindows Script Host do strange things oto me as well. Here is my suggestion, it isn't completely done through a CA:
To Read the registry key do the following, go to the Power Editor and then go to the RegLocator table. Enter the following:
Signature: MYREGKEY
Root: 2
Key: \SOFTWARE\Altiris\Altiris eXpress\
Name: DataStorePath
Value: 2
Next in the Power Editor go to the AppSearch table and enter the following:
Property: MYREGPROP
Signature: MYREGKEY
This will set a Property with the value of the DataStorePath key if a value exists. If not the Property will be blank. I am not sure why you are replacing Carraige Return Line Feeds with "". I don't know how you could get a CRLF in a reg key value but anyways, you could write some VBScript to do it:
Dim sProp
sProp = Session.Property("MYREGPROP")
sProp = Replace(sProp,chr(34),"")
Session.Property("MYREGPROP") = sProp
-------------------------------------------------------
Now you can write a Custom action to launch an executable (notepad.exe), and you can use the Property value to pass Notepad the path to whatever it is you were going to run.
Hope this gives you another alternative to using WSH.
Good Luck
Kurt Schneider