Create URL column link to open selected document properties in sharepoint 0365
-
21-02-2021 - |
Question
I have been looking for a way to create a URL in a column that will open the properties of a selected document in a document library. Has anyone been able to do this?
For instance: Select the document then click link to open the properties side menu. Instead of clicking "..." hover to more > hover to properties, then select properties. I'm trying to create an obvious one click solution.
Thanks.
Solution
Using JSON column formatting' button type, customRowAction, and editProps option, you can have a button by clicking which the property window will open for viewing/editing.
See an example below:
{
"$schema": "https://developer.microsoft.com/json-schemas/sp/v2/column-formatting.schema.json",
"elmType": "button",
"txtContent": "Edit",
"customRowAction": {
"action": "editProps"
},
"style": {
"background-color": "Transparent",
"background-repeat": "no-repeat",
"border": "none",
"cursor": "pointer",
"overflow": "hidden",
"outline": "none"
}
}
Note: Add a Single line of text column and format it with JSON above
Licensed under: CC-BY-SA with attribution
Not affiliated with sharepoint.stackexchange