Display Members of Selected Groups in Grid Columns

When selecting one or more groups, I want to display the members of those selected groups in a grid column.

Thank you!!

 .

a!localVariables(
  local!selectedGroup: ri!initialGroup,
  local!distinctUsers: if(
    a!isNullOrEmpty(local!selectedGroup),
    "Please select a group",
    getdistinctusers({local!selectedGroup}),
    ),
  local!groupName:a!forEach(
    items: local!selectedGroup,
    expression: getgroupnames(fv!item)
  ),
  local!pagingInfo: a!pagingInfo(
    startIndex: 1,
    batchSize: 10 
  ),
  {
    a!sectionLayout(
      label: "User & Group Management",
      contents: {        
        a!pickerFieldGroups(
          label: "Pick Groups",
          labelPosition: "ABOVE",
          maxSelections: 5,
          value: ri!initialGroup,
          saveInto: ri!initialGroup,
        )
      }
    ),
    a!sectionLayout(
      label: "Group members",
      contents: {       
        a!gridField(
          label: "", 
          labelPosition: "ABOVE",
          columns: {                       
            a!forEach(
              items: local!groupName,
              expression: a!gridColumn(
                label: fv!item,
                value: a!richTextDisplayField(
                  value: local!distinctUsers
                ),
                align: "CENTER",
                width: "NARROW"
              )
            )
          },
          pagingSaveInto:local!pagingInfo
        )
      }
    )    
  }
)

  Discussion posts and replies are publicly visible

Parents Reply Children
No Data