Archive

Archive for the ‘Team Foundation Server’ Category

TFS: How to fix the Red X of Death on the Report Folder in Team Explorer

March 13th, 2010 No comments

Awhile back, I upgraded our Team Foundation Server to 2008 SP1 and our SQL 2005 server to 2008.  It took a bit of finagling to get everything working right.  Google was my friend and I was able to solve all but one nagging issue.  Have you ever seen the little red “x” on your Report folder in Team Explorer?  He and I have been fighting for a few weeks.

I came across several forum posts that all seemed logical.  Here are the steps I took to get it fixed:

  1. Configure registry to use FQDN -> Edit each of the following registry keys accordingly:
    1. HKLM\Software\Microsoft\VisualStudio\9.0\TeamFoundation\ReportServer\443\Sites\BaseReportsUrl
    2. HKLM\Software\Microsoft\VisualStudio\9.0\TeamFoundation\ReportServer\443\<ProjectName>\ReportsService
    3. HKLM\Software\Microsoft\VisualStudio\9.0\TeamFoundation\ReportServer\80\Sites\BaseReportsUrl
    4. HKLM\Software\Microsoft\VisualStudio\9.0\TeamFoundation\ReportServer\80\<ProjectName>\ReportsService
  2. Configure connections in TFS
    1. Option 1:
      1. Browse to C:\Program Files\Microsoft Visual Studio 2008 Team Foundation Server\Tools
      2. Run TfsAdminUtil.exe configureconnections /view
      3. Ensure that ReportsUri is set to http://<ReportServerUrl>/Reports (or https for SSL)
        SET: TfsAdminUtil.exe configureconnections /reportsuri:http://<ReportServerUrl>/Reports
      4. Ensure that ReportServerUri is set to http://<ReportServerUrl>/ReportServer/ReportService.asmx (or https for SSL)
        SET: TfsAdminUtil.exe configureconnections /reportserveruri:http://<ReportServerUrl>/ReportServer/ReportService.asmx
    2. Option 2 (easier IMHO):
      1. Use SQL Management Studio to connect to your TFS SQL Server
      2. Run this query against the TfsIntegration database: SELECT * FROM dbo.tbl_service_interface
      3. Look for 2 records that look like these and make sure they’re accurate:
        ReportsService    http://<ReportServerUrl>/ReportServer/ReportService.asmx
        BaseReportsUrl    http://<ReportServerUrl>/Reports

At this point, I thought I was done.  The red x stared smugly into my eyes.  Alright, it must be server cache.  Reboot the server and restart VS.  He’s still there.  He’s laughing at me at this point.  I finally realized that the properties of that folder (in Team Explorer) still had the wrong url.  The cache was client side.  DIRTY!

You can clear you client cache like this:

  1. Close Visual Studio
  2. Browse to c:\users\%username%\appdata\local\microsoft\team foundation\2.0
  3. Delete the cache folder

Now launch Visual Studio and rejoice!

How to Recover Deleted TFS Files and Folders

March 3rd, 2010 2 comments

I recently went in search for a “how to” regarding file and folder recovery in Microsoft Team Foundation Server.  One of our project files was corrupted and removed its reference to an ascx file, but left the .cs and .designer.cs files behind; ultimately breaking the build on our continuous integration server.  Google doth continue to rock.  I quickly found a solution.   It’s relatively easy:

  1. In Visual Studio, click on Tools -> Options -> (make sure the “show all items” check box is checked) -> Source Control -> Visual Studio Team Foundation Server
  2. Check the “Show deleted items in the Source Control Explorer” check box
  3. Click “OK”
  4. In Team Explorer, open Source Control
  5. Then just right-click and click “Undelete” -> sooooo not a real word

Enjoy!

Can’t Synchronize TFS Warehouse after upgrading SQL Server to 2008

September 29th, 2009 No comments

I recently upgraded our TFS server from SQL 2005 to SQL 2008.  Since then, my remaining work report hasn’t run.  This makes me sad.  Bill Wang explained the reason for this and I’m grateful for it.

In a nutshell, there needs to be an assembly redirection.  This takes place per a couple settings in two (2) different web.config files.  Modify the config files in C:\Program Files\Microsoft Visual Studio 2008 Team Foundation Server\Web Services\Warehouse\web.config AND  C:\Program Files\Microsoft Visual Studio 2008 Team Foundation Server\Tools\SetupWarehouse.exe.config as follows:

      <dependentAssembly>
        <assemblyIdentity name="Microsoft.AnalysisServices"
                          publicKeyToken="89845dcd8080cc91"
                          culture="neutral" />
        <bindingRedirect oldVersion="9.0.242.0" newVersion="10.0.0.0"/>
      </dependentAssembly>

Restart IIS, then send Bill Wang a thank you note!

Tags:

Listing checked-out files in Team Foundation Server 2008 (TFS)

September 18th, 2009 No comments

I needed a list of all checked-out files in TFS today.  This page came in handy! Thanks Clay!  Here’s what he had to say (slightly modified for VS 2008)

You can get a complete list of checked out files by using the tf.exe command line tool found in: C:\Program Files\Microsoft Visual Studio 9\Common7\IDE or C:\Program Files (x86)\Microsoft Visual Studio 9\Common7\IDE for you 64 bitters.

All checked out files in $/MyProject:

tf.exe status $/MyProject /user:* /s:http://MyTfs:8080 /recursive

All files checked out to Mark:

tf.exe status /user:mark /s:http://MyTfs:8080

You can write the output to a file:

tf.exe status /user:* /s:http://MyTfs:8080 > c:\tfsCheckedOut.txt

I also created this little batch file that will automatically output results to your desktop. It’s very simplistic, but saves time having to mess with the command prompt. Edit with your favorite text editor, save, and away you go.