3

I want to get the ID of a list item each time an item created.

I have a list with couple of columns, one of columns is type Image. I want to have a list view which will show only the column Image, but when user clicks on the image he/she should get a pop up display form.

So, I want to know if it is possible to get the ID of the created item?

Basically I need to get item ID for this link:

https://link/sites/sitename/Lists/listname/DispForm.aspx?ID=<numberofitem>

Afterwards I know how and what to do.

Environment

  • SharePoint 2013
  • SharePoint Designer (I can only use SPD as a tool. I am not allowed to use Visual Studio.)
3

Create a calculated column and concat "https://link/sites/sitename/Lists/listname/DispForm.aspx?ID=" and item id. This will suffice your requirement. Also if you want to display column value as a link, check out this link.

If workflow is an option, you can start a workflow on item created and set a hyperlink column with item's display form URL. Check the screenshow below: enter image description here

Update list item:

enter image description here

  • I know all of this, but how to get item ID automatically? – Danilo Sep 7 '15 at 13:17
  • can you use workflow? – Taran Goel Sep 7 '15 at 13:18
  • Yes. I can use it. – Danilo Sep 7 '15 at 13:19
  • 1
    Then write a workflow which will update a hyperlink column. you can always find a current item ID in workflow. I'll update my answer – Taran Goel Sep 7 '15 at 13:20
  • 1
    I would suggest using current Item URL though! – Taran Goel Sep 7 '15 at 13:28
0

I'd just like to add for anyone still looking for this:

Using ID in a calculated column will not work once a new item is created or a current one is edited - The Workflow option is the best/ only option.

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.