So I have a Mapservice that consists of a number of Feature Layers. So at REST endpoint each service has a URL ending in... :
Mapserver/0
Mapserver/1
Mapserver/2
etc...
If I want to run some geometry operations on these FeatureLayers, I was hoping to create a new layer:
and then later, reference the underlying FeatureLayers as
But that results in 'undefined'. Is such only possible after I reference each sublayer when creating myLayer, such as...
Arne,
Your issue is the method is called findSublayerById NOT findSubLayersById
Robert, thanks for chiming in and for all your other contributions throughout the community. Keep seeing your name all over the place. I think I may have snuck in the extra "s" when making my post because my original code the correct method. I guess where I was going with this question was whether I can only reference sublayers that are explicitly declared when I create my MapImageLayer, which means I'd have to list foo 13 sublayers along with creating naming names for them for later reference. I had hoped there would be a way to access the sublayers along with the names visible at the REST endpoint without having to hardcode them into my MapImageLayer definition.