I'd like to only display records that have a value, in this instance, a comment while hiding Null values in a list. Is there a way to do that with advanced formatting or another solution?
Solved! Go to Solution.
If the entire line of your List template is blank, it will omit the space entirely. The easiest way is to make the "Comments:" text part of the output itself.
var comments = Iif(
IsEmpty($datapoint['Comments'],
'',
`Comments: ${$datapoint['Comments']}`
}
...
return {
attributes: {
comments
}
}
Then put {expression/comments} on its own line in the template. Should be what you want.
If the entire line of your List template is blank, it will omit the space entirely. The easiest way is to make the "Comments:" text part of the output itself.
var comments = Iif(
IsEmpty($datapoint['Comments'],
'',
`Comments: ${$datapoint['Comments']}`
}
...
return {
attributes: {
comments
}
}
Then put {expression/comments} on its own line in the template. Should be what you want.