Hi there.
I am trying to write an Arcade Expression that will show certain data if equal to more than 0, and not show data when equal to 0.
I've read the IIF and WHEN help pages and even the IsEmpty pages but I can't seem to make it work. How do I create an Arcade Expression to be used within a Custom Attribute Display?
Thanks
@AmandaBeck try the following:
if (($feature.value> 0)) {
return "Active";
}
value would be replaced with the field name. You can set "Active" to what ever you would like displayed in the legend.
Hi @JakeSkinner
I did try this, however it did not do what I wanted it to.
I already have a custom attribute expression with text for my pop ups. What I want to do is, have some text that shows and some that doesn't depending on what information is required in the pop up.
I did try this way you mentioned, but maybe When() would work?
@AmandaBeck if you're looking to hide fields in your pop-up, take a look at the following document:
https://community.esri.com/t5/arcgis-online-documents/hide-field-in-pop-up-using-arcade/ta-p/1029496