0

Our application code is spread over many dozens of folders in a nested hierarchy, and we have several hundred files making up the application.

So I wanted to know if there is a way to search for files by their name in the Visual Studio 2017 version of TFS ?

I spotted Q & A as per: TFS: Search for a file by name in source control

but this answer seems no longer applicable for TFS and Visual Studio 2017.

I can, of course use tools outside of TFS (like the "Search Everything" app) and then navigate to the same folder and file in TFS.

I just felt that surely there must be a way of doing this file search within TFS ?

I have tried the search option in Team Explorer but I'm not sure how to use this ... not sure if this works ?

i.e.

enter image description here

Allan F
  • 2,110
  • 1
  • 24
  • 29
  • TFS version and Visual Studio version is separately. To check what's the version of your TFS server, you could follow this blog: https://techcommunity.microsoft.com/t5/azure-devops/what-version-of-team-foundation-server-do-i-have/ba-p/696673 – PatrickLu-MSFT Feb 18 '20 at 10:15
  • Hi Allan, any update on this issue? Sorry, it's not support at present. Just checking to see if the information provided was helpful. If my reply helped or gave a right direction. Appreciate for *marking it as an answer* which will also help others in the community. – PatrickLu-MSFT Mar 05 '20 at 12:08

2 Answers2

1

There should be a search bar at the top of the TFS site that looks something like this you can enter all sorts of filter like those in the picture. Or you can search in files but that will only look at what you have checked out at the moment and not all over TFS. If you don't see the Search bar, it might be because your TFS Administrator did not install the search extension. You might want to contact him/her.

enter image description here

Etienne
  • 1,075
  • 5
  • 9
  • Thank you for this answer .. I don't quite know how to use this .. Do you mean in "Team Explorer" ? – Allan F Feb 17 '20 at 22:19
  • No it's on the TFS Web interface top right corner. If you are at the collection level (something like http://mytfs:8080/tfs/collection) then it's the search will look in all projects, if you are drilled down into a project then the context will search only in that project. – Etienne Feb 19 '20 at 13:02
0

There is not any out of box feature to do this in Visual Studio 2017/Team Explorer2017 directly. If you want to search folders/files by name:

  • For TFS 2017, you can use Code Search if it's been configured by your TFS admin. This is through web portal, more details please refer this doc-- Search your code

    enter image description here

  • For earlier TFS versions, you can create a local workspace and "get" that specific version locally. Then use the built in search in your OS (such as Windows file explorer) to find what you are looking for.

Hope this helps.

PatrickLu-MSFT
  • 49,478
  • 5
  • 35
  • 62