Search code examples
setup-projectvisual-studio-2022

How do I have the setup program in Visual studio install to more than one directory?


I've seen some similar questions asked here, but they don't seem to answer my specific question. Visual Studio 2020 - Setup project. My setup project currently installs files to the destination folder, we'll call it Dir.AI. All my setup's output goes there. This works fine. But I would also like my setup program to install the exact same files to Dir.LS, and Dir.TC. I.e., Setup should install all files to all three of:

\Dir.AI
\Dir.LS
\Dir.TC

I would prefer to keep this to a single install package (setup.exe and setup.msi). Is this supported?


Solution

  • Ok so take a look at this image : Types of Folder where you can install your targeted files

    Here you have multiple options to choose from if none of these fancy you look at the bottom most "Custom Folder" Here you can set your custom directory and you can create as many as you want. To set its directory location you can do that by first clicking it and then accessing its property window which will be displayed on left bottom side of visual studio panel as shown below Properties Panel

    Once that's done simply drop all your files which are in application folder same as in this custom folder and you are good to go.

    To access this panel view File system and right click on the top "File System on Target Machine".