all groups > dotnet setup > march 2006 >
You're in the

dotnet setup

group:

Duplicate (Default) value when creating new Registry key


Duplicate (Default) value when creating new Registry key Dave Rayment
3/31/2006 1:51:02 AM
dotnet setup:
Hi,

I want my newly-installed DLLs to be available on the target machine's Add
References lists, so I'm attempting to add the target directory to the
following Registry key in my installer:

HKCU/Software/Microsoft/.NETFramework/AssemblyFolders/[ProductName]

I need to add a (Default) value under this key with an associated string of
"[TARGETDIR]".

Modelling this in the setup project's Registry editor was simple, but on
installation, there are two (Default) entries under the new folder!

Is there a way to control the default value on newly-created folders or to
set it to the [TARGETDIR] value without resorting to a custom action?

Many thanks,

RE: Duplicate (Default) value when creating new Registry key Dave R.
3/31/2006 2:11:02 AM
I found the solution through some further experimentation. If you create the
string value with the name "(Default)" it does not work (i.e. it creates a
duplicate). However, if you set the name field to blank it writes the value
to the default value correctly.

I'd recommend a little note about this in the MSDN topic as it had me
stumped for hours!

Cheers,

Dave

[quoted text, click to view]
AddThis Social Bookmark Button