Force Visual Studio to think TFS is offline

Visual Studio 2008 introduced a feature that detects where the current Team Foundation Server is online or offline when you start the IDE.

In the situation where your server is actually ONLINE, but you want to treat it LIKE it’s offline, you have a couple of options.

Option 1 – Use the ‘tfpt tweakui’ utility

You can edit the server setting and go offline.

  • Close Visual Studio
  • Download and install the latest Team Foundation Power Tools
  • Start a Visual Studio Command Prompt
  • Type: tfpt tweakui
  • Open the server
  • Check the [X] Server is offline checkbox
  • Open Visual Studio

tfpt tweakui dialog

Option 2 – Yank the network cable before starting Visual Studio

Obviously the IDE won’t be able to contact the server, and will inform you that it is now offline.

Option 3 – Set a registry key

Create a *.reg file with the following text in it, and run it before starting Visual Studio.

Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\9.0\TeamFoundation\Servers\SERVERNAME]

"Offline"=dword:00000001

"AutoReconnect"=dword:00000000

When you want to go back online, you can either go to "File | Source Control | Go Online", or delete this registry key.

One Comment

  1. Posted June 1, 2008 at 10:54 pm | Permalink

    Option 3 – TFS TweakUI Power tool
    You can edit the server and go offline: http://www.virtualspot.info/gdm_images/TFS2008PowerToolsTweakUI_CC50/image_4.png

    Best,
    Lorenzo


2 Trackbacks

  1. By Arjan`s World » LINKBLOG for June 2, 2008 on June 3, 2008 at 6:56 am

    [...] Force Visual Studio to think TFS is offline – Grant Holliday [...]

  2. By Team System News : VSTS Links - 06/12/2008 on June 13, 2008 at 1:28 am

    [...] Grant Holliday on Force Visual Studio to think TFS is offline. [...]

Post a Comment

Your email is never published nor shared. Required fields are marked *

*
*