My requirement is to place newly created item on top. So I changed Sort order of newly created item programmatically using item:added event.

It works fine for when I create new item but not work when I duplicate an existing item.

So can someone suggest which pipeline I can use to change sort order of duplicated item programmatically ?


1 Answer 1


You don't need custom code.

You can set the subitems ordering for an item. I guess you need to have just for a part of tree to sort it by created day.

  1. You need to right click on an item and choose Sorting-> Subitems Sorting

enter image description here

  1. On new windows choose "Created" from DropList

enter image description here

  1. Items will be sorted ascending by created date. To have items in descending order you need to press again Sort Items and from the DropList to choose Inverse.

enter image description here

Every time when you add new items it will be added on the top .

  • Actually this is not working for me. I implemented sorting using above steps. But suppose there are 5 children in a node and i duplicate 4th child then the duplicated item gets created just above 4th item instead of top position. But my requirement is to get the duplicated item created at top position. Feb 13, 2018 at 7:16
  • what happens when you follow these steps, I tried this solution and it works fine. What is the order in your case ? Feb 13, 2018 at 7:18
  • 1
    ok, I will update my answer.You need to create custom code for it. Feb 13, 2018 at 7:20
  • In my case the duplicated item gets created just above the original item instead of top position. Because I think sort order field value gets copied from original item. Thats why its not working. Feb 13, 2018 at 7:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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