How do I get checked out files information?

Post your questions regarding using the Vault and Fortress API in your programs.

Moderator: SourceGear


Posts: 23
Joined: Fri Oct 18, 2013 1:18 pm
PostPosted: Wed Jul 13, 2016 2:18 am
I want to get the information of files that are checked out.
The code below loops through each file of checkouts.

Problem: the only (file) properties I can access are FileId and CheckOutUsers.

Expectation: I need to get File Name and additional info if available.

Code: Select all
VaultClientCheckOutList chList = ServerOperations.ProcessCommandListCheckOuts();
foreach (var item in chList.Cast<VaultClientCheckOutItem>().ToList())
{
   list.Add(item.FileID.ToString());
}

Posts: 3484
Joined: Tue Dec 16, 2003 1:17 pm
Location: SourceGear
PostPosted: Wed Jul 13, 2016 9:04 am
Take a look at the array of VaultClientCheckOutItem.VaultCheckOutUser[]. Hopefully the RepPath property of the VaultCheckOutUser gives you what you need.
Jeff Clausius
SourceGear

Posts: 23
Joined: Fri Oct 18, 2013 1:18 pm
PostPosted: Thu Jul 14, 2016 12:47 am
Thank you Jeff
That is exactly what I was looking for. ;)

Posts: 3484
Joined: Tue Dec 16, 2003 1:17 pm
Location: SourceGear
PostPosted: Thu Jul 14, 2016 7:06 am
Your welcome.
Jeff Clausius
SourceGear

Return to Questions (API)

Who is online

Users browsing this forum: No registered users and 1 guest

cron