Create an array of data in AGOL for use in arcade expression

09-05-2017 09:48 AM
New Contributor II

I would like to use Arcade in order to create a map that keys off when conditions are met. The first step to get there would be to perform a count of the number of items that are entered for a specific area. 

Say we have a field of shapes that are either in group A or B. I would like to add to the pop up what the total count of B is using Arcade. I would like to use Arcade since this value is changing over time.

I believe if I could create an array of all the values then I could use this with Arcade to complete the code. I'm working purely in AGOL.

Any suggestions would be appreciated! 

Tags (3)
0 Kudos
2 Replies
Occasional Contributor III

Xander Bakker‌ is this something you can answer?

I'm trying to use arcade in a field calculator to create a status field.  I'm using when and have quite a few different conditions for it to run through.  

One of the few conditions involve checking if a number matches one within a list.  I could do number IN (....,....,....) however I thought it would be cleaner to declare this list at the top along with other var.

How do I do this?

0 Kudos
Esri Esteemed Contributor

Hi Naomi Begg ,

Since this question is a bit off-topic from the original question posted by the OP, you might want to branch this question to a new question. However, let's see if I can answer part of your question.

You mention you want to validate the number of matched in a list. Where is this list coming from? Is it hardcoded? What is the code that you have already? Where is the data coming from? 

0 Kudos