Showing results for 
Show  only  | Search instead for 
Did you mean: 
Level 3

Create Registry Key name in a backet [123]

Hi Everyone,

How do i write a registry key in a bracket in Installshield?
For example this is my registry key

MyRegistryKey (TEST [123])

and i want to write it to the following registry key


I was able to put this key in the registry in the registry area under System Configuration but when it writes to the registry, i only see the following

MyCompany\MyRegistryKey (test)

i guess Installshield interpreted [123] as a property and it is empty so i do not see [123].

Is there anyway i can write this key? I tried using Installshield script as a custom action but it failed writing the registry key.

Thank you in advance
Labels (1)
0 Kudos
(5) Replies
Level 13

Have you tried using an escape character '\' before the brackets? I am not sure if this works or not but that is the common escape character in InstallShield.
0 Kudos
Level 8



0 Kudos
Level 3

Thank you both for replying but they did not work.
The "\" cuts the registry key and the REGDB_OPTIONS does not seem to do anything, I am still getting the RegDBCreateKeyEx write error.
0 Kudos
Level 11

If you're using an MSI based project, check this out:

If a substring of the form "[\c]" is found, it is replaced by the character without any further processing. Only the first character after the backslash is kept; everything else is removed.

So, try something like:


0 Kudos
Level 3

Have you tried coding like:

[ for left square bracket [

] for right square bracket ]
0 Kudos