View Full Version : .NET per-user installation

06-01-2004, 10:16 AM
Hi, all

I'm just about to start my next Installation Project (when my copy of ISX arrives in the next couple of days, that is). This project is a web-based application (most likely .NET-based) that has a client-side component. Therefore, we need a way of installing the client-side files, possibly along with any dependencies (such as the .NET framework).

Now, I'm thinking that the end-user may well be a normal user, rather than an administrator, which means that the install must have the minimum of user right requirements.

Are there any little nuggets of advice that anyon can offer? Anything I should be aware of.

I've had a go at creating a quick installation which just puts a few files into the LocalAppDataFolder. I got a few errors, basically consisting of the following:

- Component Component1 installs to the user profile. It must have a registry key under HKCU as its KeyPath, not a file
- The directory DIRECTORY is in the user profile, but is not listed in the RemoveFile table
- The file File1.txt will be installed to the per user directory DIRECTORY that doesn't vary based on the ALLUSERS property. This file won't be copied to each user's profile even if a permachine install is desired.

There is also one complaining that I've defined ALLUSERS in the property table.

According to these, I should either

- Create a registry key under HKCU for each component, and make that key the key path for the component, even if one is not otherwise needed
- List each directory in RemoveFile


- Install all these files to AppDataFolder rather than LocalAppDataFolder. Will this automatically install to the per-user folders if a per-user install is run? Will it work under limited user rights?

Any pointers would be greatly appreciated.


P.S: I haven't even considered the possibility of locked-down environments. Will this be an issue?

06-01-2004, 10:46 AM
Also, are there any issues with installing to the GAC under limited user rights? Do you need to be an admin to install to the GAC?

Do you need to be an admin to install the .NET framework, or technologies like the XML parser?

Thanks again

10-11-2004, 12:24 AM
the HKCU path is the keypath to the component. files under the users profile are not seen correctly when referring to self healing.

hence the use of the HKCU entry is simply a recognised way to heal the component which contains the file.

as for perms issues, users have perms to their own profiles so its not really an issue,

however in saying that items destined for "local settings" will be problematic if you use roaming profiles.

this is because the HKCU entry will exist for users with roaming profiles and therefore the file will not be healed.

normal "application data " is part of the roaming profile anyway so should be ok..

dont worry about the allusers issue too much..

if you are deploying per user you will see this issue time and tiem again and it needs to be fixed !!

10-12-2004, 04:51 AM
Ah, ok, thanks.

10-12-2004, 08:10 AM
As far as I know you need to be an admin to install files to the GAC. However Microsoft usually recommend installing assemblies in the application folder unless they're shared between multiple applications.

You might want to take a look at this article about deploying .NET apps, it's large but may answer some of your questions: