This week I finally installed Windows 10 on my main laptop at work (which is 3 years old now) paving over my old Windows 7 install. Overall the install/upgrade was super easy, fast and the results are amazing. Its like a brand new laptop again. I would definitely recommend updating if/when you have the appropriate license.
Knowing VS2017 is releasing next week, I decided to not install VS2015 or other older versions and try the VS2017 RC instead and then later update to the RTM version when its available. After a couple days this proved to be no problem for any of my VS solutions.
Then we had a corrupt TFS workspace issue in one of our CD pipelines so I reinstalled the trusty TFS Sidekick 2015 to delete it. (All TFS admins should have this amazingly useful tool installed.) As you might expect I received the following error when starting the utility:
Time to Troubleshoot
A quick look at the event log provides the underlying error:
Application: Attrice.TeamFoundation.Sidekicks.12.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.NullReferenceException
at Attrice.TeamFoundation.Sidekicks.ApplicationMain.GetVisualStudioPath()
at Attrice.TeamFoundation.Sidekicks.ApplicationMain.GetTeamFoundationPath()
at Attrice.TeamFoundation.Sidekicks.ApplicationMain.Main()
So we need to know what is causing the NullReferenceException. Telerik’s Just Decompile to the rescue! Opening the Attrice.TeamFoundation.Sidekicks.12.exe file and searching for “GetVisualStudioPath” yields the following method:
Here we can see the application is trying to open the HKEY_CURRENT_USER\SOFTWARE\Microsoft\VisualStudio\14.0_Config key and access the InstallDir value. This key/value doesn’t exist in my registry, I assume because I haven’t installed VS2015. So I added it and set the value to the Sidekick directory:
Assembly References
That resolved the null reference but I still received the following error when trying to start Sidekicks:
Failed to establish connection.Could not load file or assembly ‘Microsoft.TeamFoundation.Client, Version=14.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a’ or one of its dependencies. The system cannot find the file specified.
So it looks like the Sidekicks is missing TFS assemblies from the VS2015 install. Again JustDecompile confirmed which assemblies were missing:
After checking all the DLLs I found there were about 30 TFS/VS assemblies that Sidekicks needed through the tree of assemblies referencing other assemblies. I started looking around and found these are available via a couple Nuget packages. Unfortunately, no one package contained all the missing assemblies. In the end I found all files I needed in the following packages:
- Microsoft.TeamFoundationServer.ExtendedClient.14.95.3
- Microsoft.VisualStudio.Services.InteractiveClient.14.95.3
- Microsoft.VisualStudio.Services.Client.14.95.3
I had most of these on my box for other projects but you could also download the packages manually from nuget.org if needed. After copying these to the Sidekicks program folder the app runs as expected.
So at least for now, I only have VS2017 installed. Hope this helps others!
Thank you so much, that solution worked for me as well! 🙂
Thank you, it fixed the error!
Great to hear! Thanks for letting me/other know.
i am using vs2017 community edition and tried to install the packages you listed, however when I got to the last one, it wouldn’t install. giving me a compatibility error with the previous package install. is there a way to get these dll’s or do I need to install vs 2015?
It may be a issue with community edition. What is the error?
I don’t recall the exact issue but it said something like the last one was incompatible with another install (the second one)
Thanks!, but I am getting “Failed to connect to a Team Foundation Server TF31002.”
The URL I am providing is good (http://servername:8080/tfs) I can put it into my browser and login to the web TFS site. Any ideas? 🙁
Did Sidekick work with VS2015 installed at some point for you?
I have this same issue. Did you happen to find a resolution?
Which issue?
Great Arcticle , thanks for sharing this, this solved the issue with VS 2017
Glad to know it helped!
Thank you very much for your investigation!
You are very welcome! Glad it was helpful.
Thanks for the article. I think that this may depend on how you install Sidekicks (Current User vs All) however the steps above didn’t resolve my problem. Adding to HKLM\SOFTWARE\Microsoft\VisualStudio still caused Sidekicks to fail. I instead used HKCU\SOFTWARE\Microsoft\VisualStudio and added 14.0_Config there and everything worked ok. Thanks again!
Great, thanks for sharing!
Hi,
I have an issue when I right click->View Changeset Details on a changeset. It crashes because it cannot find the Microsoft.TeamFoundation.VersionControl.Controls.dll (version 14.0.0.0).
Any idea where to find this dll (to the best of my effort, I checked various nuget packages without success)?
Anybody had this issue and resolved it in any way?
Nevertheless, the rest of the application works great and thank you a lot for the post.
Regards
This solution doesn’t work for Visual Studio Online (VSTS). Login result is “Access denied”. After installing VS2015 and VSTS connection configuration everything works.
Any solution without installing VS2015?
Yeah, we were testing with TFS on prem. Not sure why VS2015 would be required for VSTS only. If you figure it out please share the solution here for other readers. Thanks!
Good information. Have you had any issue with Status Sidekick no longer working? I’ve still got VS2015, using it as normal. The rest of the sidekicks work fine, but it seems like status sidekick just fails to return values. Thanks!
Actually, I changed jobs and haven’t used this setup in 6 months or so.
The Attrice site is no more. 🙁 We still have legacy code in TFS and I wish Microsoft had a native solution for this.
Thank you very much for this great solution and article. It was very helpful.
Thanks for your clear explanation. it really helped.
I also had the issue with the Microsoft.TeamFoundation.VersionControl.Controlls.dll. I am migrating to a new computer, but still have access to the old machine with VS2015 installed on it. I found the dll’s in the same folder the others came from: “C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions\mnstxstd.1ae”
I am (temporarily) stranded on Microsoft.VisualStudio.VisualTreeGrid.dll maybe I fix it on monday, I’ll probably update this if I do.