hi all, I need to a extract the value for a particular field in a feature layer when a user clicks on a given feature. I don't need to display the field value in a popup but just to use that value elsewhere in my code.
I'm assuming I need to define a feature layer but not sure on the rest.
I see examples extracting field values using a (feature layer).on { } event listener and then displaying the values in a popup with this "$" notation. But I don't think this is what I'm looking for.
I also see there's a QueryTask object that returns a FeatureSet and presumably I can extract the value from that, but I can't find an example that shows the precise syntax.
Appreciate any help, thanks!
Dan
Solved! Go to Solution.
Hey, check this example.
Query data without a map | ArcGIS API for JavaScript 3.27
So instead of making a popup u can get the parameters easily with the for sentence over there.
I hope this help u
Hey, check this example.
Query data without a map | ArcGIS API for JavaScript 3.27
So instead of making a popup u can get the parameters easily with the for sentence over there.
I hope this help u
Thanks Evelyn, I overlooked this, hopefully it's what I need!