Select to view content in your preferred language

What is the JavaScript 4.x way to set the Dynamic Layers parameter for an Identify request?

498
2
10-04-2017 06:17 AM
JimLawruk1
New Contributor II

In the API for JavaScript 4.5, when executing an Identify request, how do you set the dynamicLayers parameter?  This allows you to run one Identify request for multiple dynamic layers that have a query table data source. In other words, the layers are not defined, but created on the fly.  In the 3.x world, you set the IdentifyParameters dynamicLayerInfos property.  In 4.x, the IdentifyParameters class no longer has this property.   Thanks!

Tags (2)
0 Kudos
2 Replies
ThomasSolow
Regular Contributor

The documentation for IdentifyTask in the 4.X SDK says:

IdentifyTask is not supported if attempting to be used:

That said, the JS API only provides a wrapper around the REST API here.  The real functionality to handle this stuff is on the server so there's no reason you can't write your own function to make an identify request (probably using esri/Request) which includes dynamicLayers.  The REST API documentation should be useful if you decide to do this.

JimLawruk1
New Contributor II

Okay, thanks. I should have noticed that. I wonder if it will be supported in the future of if they are steering away from this type of request.  Regardless, I can build the request manually as you suggested. Thanks again.

0 Kudos