How can I exclude files at design-time using C#?

I am authoring a Visual Studio Plug-In where I need to exclude files by name from solution code refactoring. I know I can manually do this in options but I need a way to update the settings to omit files using code. 

Here is how I would do it manually:


It would probably be enough if I could access the file where the exclusions are created and update that using some code.  I can't seem to find where these are kepts.


Please sign in to leave a comment.