Is it possible to lock a branch using TFS API in TFS 2010?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
I am assuming you already know how to connect to TFS and get a specific workspace.
With that said, you would use Workspace.PendEdit for this.
Workspace.PendEdit Method (String[], RecursionType, String, LockLevel)
The enum LockLevel is defined here:
LockLevel Enumeration
This acts the same as the UI if you were to right-click inside of TFS on the branch itself and perform the lock.