Remove Source Control Association From Your .Net Projects

Posted In Tutorials - By NitiN Kumar Jain On Friday, February 25th, 2011 With 0 Comments






Pin It


There are times when while working on your .net project and not connected to network or slow connectivity, you face problems when opening the solution or project files. One of the reason could be that the solution / project file has association with some source control and having no/slow connectivity the solution goes to infinite hanging state and you can’t do anything except killing the process. That’s what I faced recently and found the solution too.

To just make your .net solution  not try to connect to the source safe before loading, make the following change in the solution (.sln) file:

  1. Open the .sln in any text editor (notepad).
  2. Look and remove the following section:

GlobalSection(SourceCodeControl) = preSolution

EndGlobalSection

Making above change only is enough to let you open your solution. Individual projects will then ask you to remove source safe association temporarily or permanently. You may choose any option.

If you want to remove complete source control association from your solution/project then in addition to the above  point do following changes too:

  1. Go to the solution folder and search “*.*scc” within the folder hierarchy and delete all files.
  2. This should basically delete the following files.
    • mssccprj.scc
    • <solutionname>.vssscc
    • <projectname>.csproj.vspscc / <projectname>.vbproj.vspscc
    • vssser.scc
  3. You may also want to modify individual project files (not mandatory)
  4. Open the *.proj files and delete the following:
    • SccProjectName = “SAK”
    • SccLocalPath = “SAK”
    • SccAuxPath = “SAK”
    • SccProvider = “SAK”

Step 4 is optional as it will be automatically done when you permanently remove the association when you open the project for the first time.

You should be source control free now.