TFS API: GetLocalWorkspaceInfo always returns null

After migrating from TFS2013 to TFS2017 in the company I work for I had the same problem with Workstation.Current.GetLocalWorkspaceInfo. What worked for me is a call to Workstation.EnsureUpdateWorkspaceInfoCache: TfsTeamProjectCollection tpc = TfsTeamProjectCollectionFactory.GetTeamProjectCollection(new Uri(“<your-tfs-uri-here>”)); VersionControlServer tfServer = tpc.GetService<VersionControlServer>(); Workstation.Current.EnsureUpdateWorkspaceInfoCache(tfServer, tfServer.AuthorizedUser); I added the above code lines to the constructor of my TFS proxy class that uses … Read more

TFS API – How to fetch work item(s) from specific Team Project

You could try something like this for getting all WIs within teamProject: WorkItemCollection workItemCollection = workItemStore.Query( ” SELECT [System.Id], [System.WorkItemType],”+ ” [System.State], [System.AssignedTo], [System.Title] “+ ” FROM WorkItems ” + ” WHERE [System.TeamProject] = ‘” + teamProject.Name + “‘ ORDER BY [System.WorkItemType], [System.Id]”); And this to get a specific WorkItem ID: WorkItem workItem = workItemStore.GetWorkItem(555);

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)