Select to view content in your preferred language

Identify Parameters layerOption

767
1
05-25-2011 05:35 AM
GeorgeNewbury
Frequent Contributor
For the identify parameters layerOption, you can choose from:
'LAYER_OPTION_ALL', 'LAYER_OPTION_TOP', 'LAYER_OPTION_VISIBLE'

These options query against the default service visibilities and layer orders, correct?

I was putting together the the identify sample with the toggle layer example, and even though I turned a layer off, I would still get an identify result if I clicked on a feature. For example, turn off lakes, click where a lake is, and I'd get the lake even though it wasn't visible.

Thanks,
George
0 Kudos
1 Reply
KenDoman
Frequent Contributor
It may depend on when you set the IdentifyParameters. If you set the extent and visibility options at the beginning of your session, then zoom to another location and turn on/off layers, the parameters won't be correct. If you set those options during the click event, the parameters are more up-to-date, and the identifyTask result should be closer to what you want.

--Ken
0 Kudos