Welcome to Vishwa's blog - Technology, Spirituality and More...

Visual Studio Team Foundation Server

FOR VS 2012

First Check the existing workspaces for some "computername" can be queried with this TFS command:

tf.exe workspaces /computer:computername /owner:* /format:detailed /server:serveraddress

You get a list of all workspaces, with the existing mappings. It is the workspace name (behind "Workspace:") and the owner that you need in order to delete the workspace.

Now run this TFS command to remove the workspace "workspacename" for owner "owner":

tf.exe workspace /delete workspacename;owner /server:serveraddress



FOR VS 2010

Recently came across some issues while upgrading from Visual Source Safe (VSS) 2005 to Visual Studio Team Foundation Server (VSTFS) 2010. Found some workarounds and limitations. I am assuming you are using Visual Studio 2010

On TFS Server Machine

1. If your projects are using .NET framework 3.5 or higher, make sure the respective .NET Framework is installed on the Server

2. Make sure that output folder where TFS will build the projects have write permission

3. If you are using Enterprise Library or any third party tool, they are also installed on the Server.

4.  You may get an error during Build of the project about “Microsoft.WebApplication.targets“, to resolve this issue C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v10.0\WebApplications\Microsoft.WebApplication.targets from local (development) machine which had VS 2010 already installed.

5. If you have some components or dlls for which you do not any installer or they can not be installed in GAC but they are referred in your projects, One way to fix this issue is to copy that dll in to into C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.0

Some informative links


On Development Machine

How to Find your workspaces?

Go to Visual Studio Command Prompt, and use one of the following commands

C:\tf works

In order to delete any of the workspace, you can use following command

C:\>tf workspace /delete /server:BUILDSERVER WORKSPACENAME;OWNERNAMEpaces /owner:*

Important: Make sure that the TFS still has the same collectionname and path. If you or administrator deleted a collection directly from TFS you will not be able to delete or clear your old workspace. Microsoft should have provided a way to address this problem.

How to Delete a Collection?

1. Go to Command Prompt

2. Go to C:\Program Files\Microsoft Team Foundation Server 2010\Tools

3. Type C:\TFSConfig Collection /delete /collectionName:[COLLECTION NAME]"

Note: Delete does not delete from TFS, but just marks the item as deleted, in order to fully delete it, you will have to destroy it


How to Destroy?

1. Go to Command Prompt the

2. Go to C:\Program Files\Microsoft Team Foundation Server 2010\Tools


For more info visit following link