Question

I want to create a Visual Studio 2010 setup project that deploys some files to a folder where my application can use it from. I want it so, that all users have the same files, and that they also could manipulate them without admin rights.

Thus, "Common Application Data Folder"* as described in this MSDN article, seems fine.

However, in my Visual Studio 2010 setup project I did not find the "Common Application Data Folder" available in the "Add special Folder..." drop down menu.

I have a .NET 4.0 WinForms app and see no reason why this does not show up. The user's common application data folder is available but does not match my intended use.

Thanks for any hints!

Was it helpful?

Solution

Visual Studio setup projects do not have a predefined folder for common Application Data. However, you can install files in it like this:

  • add a custom folder and select it
  • in its Properties pane set DefaultLocation to:

[CommonAppDataFolder]
  • in this folder add the files you want installed in common Application Data

During install CommonAppDataFolder will be automatically resolved by Windows Installer.

OTHER TIPS

A more specific solution might be to set the DefaultLocation property to:

[CommonAppDataFolder][Manufacturer]\[ProductName]

Manufacturer and ProductName will be resolved from the values you assign to the corresponding properties of the setup project.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top