16

I would like to get a list of all checked-out items in the system with the Core Service. I have a feeling I need to use:

 GetSystemWideList(filter)

But, I can't find a filter to give me the list. What filter would I need?

Update: Here is the complete working solution

// get all checked out items from core service
string binding = "netTcp_2011";
SessionAwareCoreServiceClient client = new SessionAwareCoreServiceClient(binding);

RepositoryLocalObjectsFilterData filter = new RepositoryLocalObjectsFilterData();
XElement checkedOutItems = client.GetSystemWideListXml(filter);
  • I don't get it... The code indeed does return all the checked out items. But I don't get the relation between the filter object name (RepositoryLocalObjectsFilterData) and the behavior that it returns all the checked out items. And when the flag LockFilter = LockType.CheckedOut it returns nothing. Does anyone know? – Ayhan Yerli Nov 20 '18 at 10:31
17

You need RepositoryLocalObjectsFilterData, this filter will behave differently if you specify properties, like ItemIds, but without setting any properties you will get all checked out items in the system (provided you have enough permissions.)

  • Any idea how to do the opposite? That is: enumerate items not checked out. (Need to manipulate items' history and now it throws: "Unhandled Exception: System.ServiceModel.FaultException`1[Tridion.ContentManager .CoreService.Client.CoreServiceFault]: The item is checked-out." – esteewhy Jun 14 '13 at 9:06
  • Can you ask it in a separate question? It's difficult to understand what you need – Andrey Marchuk Jun 14 '13 at 9:12
  • Sort of resolved my own pain. Relevant condition is this: LockType.None != ((FullVersionInfo)versionedItem.VersionInfo).LockType – esteewhy Jun 17 '13 at 8:20

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.