Hey guys
I'm a bit new to arcade and trying to figure out how to do a simple expression in field maps to fill in a value.
I have field1 with a string and field2 with two possible values via domains. If in field1 a specific string is chosen, I want field2 to select the correct value (from the domain) automatically.
I tried it like that:
if ($feature.field1 == "string 1") {
var output = DomainName($feature, "field2", 1);
return output;
}
or without specifying that it's a domain:
if ($feature.field1 == "string 1") {
var output = "string2";
return output;
}
Im not sure if the second option is possible because there is a domain set on the field.
But nevertheless, both didn't work.
Can someone help me? It's probably simple and I don't get something right.