Excluding Items from a Deployment Project
Sometimes you may want to exclude a file or files from a deployment project. For example, the common language runtime will be added to a project as a dependency of any application that uses the .NET Framework. If you know that all target computers for your application already have the common language runtime installed, you can exclude this file and greatly reduce the size of your installer.
To exclude a file
In Solution Explorer, select the file that you want to exclude.
In the Properties window, select the Exclude property and set it to true.
Note Excluding a file in one configuration excludes it for all configurations of a project.
See Also
Adding Items to a Deployment Project | Deploying Applications | Opening the Deployment Editors | File Installation Management in Deployment | Setting Deployment Project Properties | Adding and Removing Folders in the File System Editor | What's New in Deployment