AnsweredAssumed Answered

Getting Field information off Sublayer of a MapImage Layer

Question asked by cameronsmith@vhb.com_VHB on Oct 3, 2018
Latest reply on Oct 4, 2018 by cameronsmith@vhb.com_VHB

Hi,

 

I am creating an application with arcgis js 4.8 api. I bring in a WebMap into this application, which has a MapImage Layer. This MapImage Layer has multiple sublayers. I need to know the fields that exist in these sublayers, and I also need to know the type of each field (number, string... etc). The sublayer interface is here: Sublayer | API Reference | ArcGIS API for JavaScript 4.9. I can use the "popupTemplate" in the sublayer and then go into the fieldInfos property of that to get the names of the fields, however that does not have the type information for each field. Does anyone have any idea how to get the type information for each field of a sublayer?

 

Thanks

Outcomes