how does visual studio determines the active solution configuration? - visual-studio-2013

I am using VS 2013 and created a custom solution configuration -- "Debug with Flag" - "Any CPU". We have central version control system, where we checkin our code. For some reason everyones' VS environment has this new configuration as active. I don't want this to show as active for others unless they explicitly change it. Also i didn't find option to set default active configuration on VS. Any ideas, why everyone is getting this new custom config as active one?

Related

Visual Studio 2015 Config Transformation option missing

I just installed Visual Studio Prof 2015 (Ver 14.0.2542501 update 3) on Windows Server 2012 R2. I also installed Configuration Transform Extension. I am domain admin, and have added developers group into the local admin group and remote access group.
When I open VS and right click on app config for a project, I can see the Add Config Transformation option; however when a developer remotes into the machine as (they are also admin), the right click menu does not have the Config Transformation option.
I'm unsure as to why this is happening, since both Environments are set to "General", so I'm guessing it's a permissions thing?
Config Transformation option missing
Config Transformation option available
Make sure the configuration exists first (you probably already have Debug and Release). If it doesn't, then add it in the Configuration Manager (ie. Test, Prod, ...). Once you have the configuration in place, build the solution and click the "Show All Files" button in the Solution Explorer.
Solution Explorer Top Bar
Expand the Web.Config and all the configuration transforms will be present that previously existed. If you created a new configuration, then switch to that build. Right click on the Web.config file and the option to add a configuration file for your current build will be present.

In VS2010 the configuration list in Project Property Pages does not match the one in Configuration manager. How do I fix this?

I have an old Visual Studio 2010 Project with a lot of configurations. In an effort to refactor/make sense of the project I decided to shuffle around and re-name some of those configurations (Using the Edit option in the Configuration Manager). The problem? The list of the configurations available in the Project Property Pages (where one can change compiler or linker options etc.) still displays the old names! This can be very confusing and the lack of consistency is infuriating.
I tried restarting Visual Studio and deleting the .user and .sdf files - those didn't help. I even tried to manually Search&Replace the old names with new ones in .vcxproj and .sln files. The only result of that was being unable to open the project properly (does not build).
Is there anything I have done wrong? Can I do anything to restore some order into this project?
I suspect the behaviour I described is a bug in Visual Studio 2010 but I have eventually found a way to do what I wanted despite it.
In order to fully change the name of a Project/Solution Configuration:
Open Configuration Manager
Select <Edit...> from the "Active solution configuration" drop-down list
Change the name of the configuration you want to edit and close the Edit Solution Configurations window
In the "Project contexts" section of Configuration Manager, open the "Configuration" drop-down list. You will notice that the configuration which name you've just changed still has it's old one there. Select <Edit...> once again and change it to whatever you did in step 3.
Visual Studio will notify you in an error prompt that "The operation could not be completed". This is (partially) wrong.
Close the prompt, the Configuration Manager and finally close the solution (from the File menu) saving any changes to it.
Re-open the solution.
Go into the Configuration Manager and once again inspect the relevant "Configuration" drop down in the "Project contexts" menu. You will notice that although initially the old configuration name is displayed, the drop down figures only the new one. Select it. Otherwise attempting to access Project Properties will now generate another "The operation could not be completed" error.
The configuration should now function under its new name.

Visual Studio Build Configuration - Release Pro

In Visual Studio 2013 I see there is new configuration for build (Release Pro).
When deploying in production, I normally choose Release. So not sure what this Release Pro and how it differs from Release
Will it increase speed?
Cheers.
I have no such new default configuration. Probably one or more of your projects have a custom configuration called RELEASE PRO with some kind of personalization (Conditionals symbols like #if DEFINE_CONSTANT to include/exclude piece of code is the most common reason).
You need to check the projects that are included in the solution to find the ones that uses this configuration and decide if you want to keep it for your building scenarios.
If the configuration is no more needed (Check with the uttermost attention your proejcts) you could use the Configuration Manager menu to remove it:
Build->Configuration Manager
Select Edit from the Active Configuration then Remove
This article on MSDN seems a good starting point to understand the need of a custom configuration Understanding Build Configurations

VS 2013 Create Per-User Publishing Settings

We've recently upgraded to Visual Studio 2013 and we're having some issues with the new way publishing is handled. Previously, (in VS 2010) every user had their own local publishing settings, but in VS 2013 it's changed to the idea of shared publish settings. This is causing problems with our environment because every developer has a different local dev environment (paths, connection strings, email addresses to send things to). I realize this is not the optimal way to have things set up, but that's the reality of our situation right now.
We use config transforms to handle the various web.config changes for different developers, so just running through VS doesn't work for us because it doesn't run the transforms. This also causes a problem with the VS 2013 publish settings because the last build config used is stored in the shared publish settings. In order to keep all our settings different, it looks like we're going to need to have a different publish setting for each developer now as well (such as "Local - Erik", "Local - OtherDev"). This is just going further down a path I'd like to get out of eventually.
So my question boils down to: Is it possible to somehow disable the shared profile settings? I thought of just not including them in version control, but then Visual Studio complains that the files are missing on other developers' systems.
Thanks for the help!
You can do this by excluding the profile from the project after you create it. The publish wizard looks for any profile on disk, but newly created ones are added to the project by default. If you then exclude the .pubxml file from the project and remove it from source control, it shouldn't bother you again.

How to configure Visual Studio to use different source control providers

I'm involved in many projects and each project has their own source control provider. Is there a way to configure Visual Studio 2010 to automatically select the right source control on a per project basis? Or is the Tools - Options - Source Control plug in per user level?
Let me clarify what is happening. I have a project using Vault. When I open it VS sets the Source Control to Vault. I then close the project (solution) and open another solution that uses Mercurial (VisualHG) I check the Source Control plugin and Vault is still selected. Why? Is it possible to automatically select the right source control?
In order to automatically load a proper source control provider the solution file must contain Scc bindings.
I don't know if VisualHG supports them or not.
But you can try HgSccPackage - another mercurial plugin for MS Visual Studio 2008/2010 which supports Scc bindings.
You can get it here: http://www.newsupaplex.pp.ru/hgscc_news_eng.html
If you want to add Scc bindings to an existing controlled solution, use Mercurial -> Change SCC bindings menu from the IDE. (This menu will be available when the HgSccPackage is active and you have loaded a controlled solution).
For new projects HgSccPackage automatically adds Scc bindings. It is configurable via options though, for thouse who don't like this behavior.
You might want to take a look at this question. It appears the answer is no, you have to select the correct provider for the project before working with the project, because only one source control provider can be active at a time.
There's an additional VS plugin called Scc Auto Switcher that can help automatically switch between SCM systems used by different projects, although the docs don't specifically mention Vault.

Resources