Problems with symbology based on Arcade in ArcGIS Pro 2.2

1891
13
Jump to solution
06-29-2018 06:45 AM
XanderBakker
Esri Esteemed Contributor

I have a project that I created in the previous version of ArcGIS Pro, but after updating to 2.2 it does not visualize the symbology based on Arcade. Perhaps a glitch I thought so I created a new project, added the featureclass and defined Unique Values and created the expression based on a script I have used before (see: Visualizar el esquema de barrido y el próximo barrido en una ventana emergente con Arcade ). 

Arcade expression:

var dct_schedule = {'L-J': [0, 3], 'M-V': [1, 4], 'W-S': [2, 5], 'LWV': [0, 2, 4], 'MJS': [1, 3, 5], 'LaS': [0, 1, 2, 3, 4, 5]};
var lst_schedule = dct_schedule[$feature.FRECUENCIA];

var resultado = 'Otro día';
var dia_actual = Weekday(Now()) -1;
var test = IndexOf(lst_schedule, dia_actual);

if (test != -1) {
       resultado = 'Barrido hoy';
} else {
       resultado = 'Barrido otro día';
}

return resultado;

When I validate the expression it validates OK:

However, when I apply the expression this happens:

I notice that the buttons present in the Symbology pane have changed, but did something change to the underlying support for Arcade expressions?

CC Kory Kramer 

0 Kudos
1 Solution

Accepted Solutions
KoryKramer
Esri Community Moderator

We've checked and this is fixed in ArcGIS Pro 2.3 which should be available in late January/early February.

View solution in original post

13 Replies
PetrBlahník
New Contributor II

I have the same problem with this Arcade expression: 

var prilohy = $feature.Prilohy
var okna = $feature.Okna_menena
var pnull = IsEmpty(prilohy)
var onull = IsEmpty(okna)

when (((prilohy==0||pnull==true) && (okna==0||onull==true)),"bez",(prilohy==1 && (okna==0||onull==true)),"Budova s přílohami",((prilohy==0||pnull==true) && okna==1),"Budova s realizovanými IPHO",(prilohy==1 && okna==1),"Budova s přílohami a realizovanými IPHO","nic1")‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍
0 Kudos
AlessandroValra
Occasional Contributor III

I have a similar problem, getting the same warning message and no way to set the symbolgy. Any update on this?

0 Kudos
XanderBakker
Esri Esteemed Contributor

Nope, same behavior in ArcGIS Pro 2.2.2 still returning the same error. Expression is valid:

However, it will not load the values from the expression:

 

Kory Kramer , if you want I can send you the data to reproduce this. It works correctly in ArcGIS Online.

KoryKramer
Esri Community Moderator

Hi Xander Bakker‌.  

Sure.  It would be good to get an example that fails.  Interestingly, I just found this bug:

[BUG-000117086: Error received when trying symbolize a feature layer using custom symbology through an arcade expression in ArcGIS Pro when the machine region format settings are Swedish(Sweden) .]

For those on this thread, are you on Windows 7 or Windows 10?

What are the region and language settings?

Cheers

XanderBakker
Esri Esteemed Contributor

Hi Kory Kramer , thanks for digging into this. 

Although I am a huge fan of the Swedish cook of the muppets...

...my regional settings are actually Spanish (Colombia) and I'm using Windows 10 Pro. I'll mail you the data and expression that I am using.

0 Kudos
KoryKramer
Esri Community Moderator

That's hilarious, Xander Bakker‌!  Here is my hunch - the bug was written to be too specific.  This could be the case with any region/language setting other than English.  We'll need to investigate.

0 Kudos
XanderBakker
Esri Esteemed Contributor

Thank KKramer-esristaff , I just sent you a mail with the data and the expression and an example of how it looks in ArcGIS Online.

0 Kudos
KoryKramer
Esri Community Moderator

Xander Bakker‌ I set my country to Colombia and default language to Espanol (Colombia) and the expression works fine in ArcGIS Pro 2.2.2.

So it doesn't seem that it is just ArcGIS Pro 2.2.x, but something else about the machine, combined with 2.2.x that leads to this.  

XanderBakker
Esri Esteemed Contributor

Hi Kory Kramer , thanks for testing! I wonder what the problem could be. This happened also in my machine at 2.2.1 (and perhaps even in 2.2 if I recall correctly). I will test it out at home where I have a Dutch OS to see if that gives a different result and with some colleagues at the office to see if using a different computer makes a difference. What else can you recommend me to test?

0 Kudos