myESRIUName

"visibleLayerschanged" event?

Discussion created by myESRIUName on Dec 5, 2012
Hello all,

Is there such a thing as a "visibleLayerschanged" (or whatever it may be called) event?

What I'm looking for is an event that is triggered when the visibleLayers for a service is changed? The only thing I can see is an "onUpdateEnd" event but that might be triggered by adding a service or changing the symbology of a layer or changing the visibility of a layer because the map's scale changed, as well as by the use of the  setVisibleLayers() method. There doesn't appear to be any way to tell what action actually triggered the "onUpdateEnd" event and the functionality I'd like to invoke when setVisibleLayers is changed isn't something I want to happen every time the map is updated.

Can anyone tell me if there is such a thing or some way to trap for that type of event that I'm not seeing in the docs?

Cheers,
jtm

Outcomes