Feb 04 2021 02:12 AM
Hi all,
following requirement:
I want to copy the value of the ID field in a document library to another column (e.g DocID) within the same document/item.
Is it possible to use lookup column for this? I´ve tried it but I have to assign the ID then manualy.
I want to avoid to use a flow and would prefer an out of the box approach.
Feb 04 2021 03:14 AM
There is no SharePoint out of the box way to store/save the value of ID in another column. Possible workarounds:
To store the value in another column:
To show the value in another column in document library/list view:
In SharePoint online modern experience, you can use JSON column formatting to show the value of ID column in another column in library/list view. Use below JSON for this:
{
"$schema": "https://developer.microsoft.com/json-schemas/sp/v2/column-formatting.schema.json",
"elmType": "div",
"txtContent": "[$ID]"
}
Please click Mark as Best Response & Like if my post helped you to solve your issue. This will help others to find the correct solution easily. It also closes the item. If the post was useful in other ways, please consider giving it Like.