Forum Discussion

aleyna6060's avatar
aleyna6060
Copper Contributor
Jan 19, 2023
Solved

Format Lookup Column

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 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

    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.

2 Replies

  • 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

    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.

Resources