I have a field named CVA_Partner_ and it has a value of either yes or no. If it is yes, Yes, Y, or y, I need it to display an image in the pop-up. Otherwise I don't want anything to display. I selected 'add content', 'image', and I placed the an expression in the URL field, but nothing happens in the pop up. I seem to be confused have this works.
Below is the expression:
Dear Skysurfer,
Hope this message finds you well,
Please follow this steps if you are using ArcGIS Pro,
1) Right click on the feature layer in the content pane and select Configure Pop-ups,
2) In the Configure Pop-ups Pane click on Arcade in the right up corner
3) Define a name for you pop-up in the Title field
4) Double clikc on the Expression in the below of the Title and paste the arcade.txt which I put in the attachment.
It should work,
if you need more info please let me know
Best wishes
I am using AGOL. So any other solutions would be great.
Instead of using the Image content, use Arcade element. This would be your expression
var output;
if (Lower($feature.CVA_Partner_) == "yes" || Lower($feature.CVA_Partner_) == "y") output = '<img src=".../sharing/rest/content/items/78df60bf1f274f26b96176d9975cdbf7/data" alt="Image">'
return {
type : 'text',
text : output //this property supports html tags
}
Dear Skysufer,
As @KenBuja said, you can use in AGOL his method,
I have created a sample Feature layer which you can find the link below.
If you click on items you will see one of the below images,
Please find the updated arcade.txt file in the attachment. Please copy the arcade.txt file content in the Pop-ups section click on Add Content, select Arcade, delete what is inside and paste the arcade.txt file content in it.
If you need more clarification please let me know.
Best wishes, Stay Safe