We had a Core Service script running that left thousands of Components checked out.
I would like to fix this with another script based on Robert's example (http://www.curlette.com/?p=1095). I don't see errors but nothing seems to happen. Is there something else I can try?
Update
My simple script (used with LINQPad)
RepositoryLocalObjectsFilterData filter = new RepositoryLocalObjectsFilterData();
XElement checkedOutItemsXml =Tridion.GetSystemWideListXml(filter);
checkedOutItemsXml.Nodes().Count().Dump();
ReadOptions ro = new ReadOptions();
ro.LoadFlags = LoadFlags.Expanded;
foreach (XElement tridionItem in checkedOutItemsXml.Nodes())
{
if (tridionItem.Attribute("Type").Value == "16" || tridionItem.Attribute("Type").Value == "64")
{
VersionedItemData response = Tridion.CheckIn(tridionItem.Attribute("ID").Value, ro);
}
}
client.UndoCheckOut()
method. Are you running the new script as an admin user? Can you 'manually' undo the checkout (or check-in) on these items successfully?UndoCheckOut
instead indeed).