SOLVED

Format Lookup Column

Copper Contributor

Hello, if I select several things for a lookup column. The information is not listed one below the other, they listed next to each other.

Can i change that?

The number is the lookup field, here I select the person with the number. The remaining 2 columns are then the fields that are automatically recorded. Exactly these fields I want to format

 

aleyna6060_0-1674118157931.png

 

2 Replies
best response confirmed by aleyna6060 (Copper Contributor)
Solution

@aleyna6060 You can use JSON column formatting for extended lookup columns. Use JSON like: 

 

{
  "$schema": "https://developer.microsoft.com/json-schemas/sp/v2/column-formatting.schema.json",
  "elmType": "div",
  "txtContent": "=join(split(@currentField, '; '), '\n')"
}

 

Output

ganeshsanap_0-1674126570879.png

DocumentationSharePoint JSON column formatting 


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.

Thank you so much!
1 best response

Accepted Solutions
best response confirmed by aleyna6060 (Copper Contributor)
Solution

@aleyna6060 You can use JSON column formatting for extended lookup columns. Use JSON like: 

 

{
  "$schema": "https://developer.microsoft.com/json-schemas/sp/v2/column-formatting.schema.json",
  "elmType": "div",
  "txtContent": "=join(split(@currentField, '; '), '\n')"
}

 

Output

ganeshsanap_0-1674126570879.png

DocumentationSharePoint JSON column formatting 


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.

View solution in original post