Hi,
For what you need you can try this approach:
- in the
Custom Actions page create a
Property set with Formatted custom action under "InstallExecuteSequence" -> "CostFinalize" (you can show "CostFinalize" by using the "Show Standard Action" toolbar button)
- set the "Property Name" to USER_FOLDER_SHORTCUT
- for the "Formatted Text" field use the "Edit" button to select the folder
- under this custom action create another one which modifies the USER_FOLDER_SHORTCUT property, replacing "\" with "\\"
- use the USER_FOLDER_SHORTCUT property for the shortcut
For modifying the property value you can use this VBScript code:
Code: Select all
Dim path
Dim modifiedPath
Dim tokens
path = Session.Property("USER_FOLDER_SHORTCUT ")
path = path & "$"
tokens = Split(path,"\", -1)
i = 0
modifiedPath = ""
Do While tokens(i) <> "$"
modifiedPath = modifiedPath & tokens(i) & "\\"
i = i + 1
Loop
Session.Property("USER_FOLDER_SHORTCUT") = modifiedPath
This code can be pasted into a .VBS file which can be added as an attached custom action. After the "Property set with formatted" sets USER_FOLDER_SHORTCUT to the folder path, the script replaces "\" with "\\".
Regards,
Cosmin
FOLLOW US
Get the latest news in Application Packaging