1

I have a list where the user can add new items. I would like to generate an ID based on who creates the item.

For example

  • if Person A is the creator, then her ID="10000 + number of items she created". So her first item is 10000, the second is 10001, the third is 10002...

  • If person B create an item the ID is 20000 + number of items. I have 5 user in total.

Any method is fine. My plan is to create a list where I store how many items were created by each user and get information from it and update when new item is created. I think I should use workflows, but I don't have experience with them.

Thank you very much for any suggestion!

3

First, The ID and Created by are not supported fields in the Calculated Column, For more details check THE SUPPORTED AND UNSUPPORTED COLUMNS IN SHAREPOINT CALCULATED COLUMN FORMULA

Second, there is a supported Count function that can be used in Calculated Column but based on your scenario it's useless.

Third, Based on your description, you said "My plan is to create a list where I store how many items were created by each user" so I think you can achieve this by creating a new view in the same list Grouped By the Created By

enter image description here

It would give you how many items created by a specific user as shown below

enter image description here

Finally, using SharePoint Designer workflow would be complex and maybe not satisfy your requirements, because you will not be able to control the count of items based on the current user!. and I think it's preferred to use Event receiver as a coding solution to achieve this scenario!

  • Very clear and helpful advice thanks! What I forgot to mentinon is, that the users may delete items too. Is this "Group By method" shows the actual or the total number of item created by a user? – Nefri Sep 25 '17 at 9:32
  • it shows the actual in the current list! Please don't hesitate to inform me if you need further clarification also Please don't forget to mark the answer if it helped you :) Thanks! – Mohamed El-Qassas MVP Sep 25 '17 at 10:09
  • I upped it thank you! May I ask what method would u prefer if the user can delete items too, so we need the total number if items created by the user to be able to create an uniqe ID? – Nefri Sep 25 '17 at 10:30
  • Sorry, I don't get your point, but there is already unique ID for each item you can show it in your view by modifying the view from the above ribbon – Mohamed El-Qassas MVP Sep 25 '17 at 16:55

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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