Select to view content in your preferred language

Event after setDefinitionExpression has been applied

3706
3
Jump to solution
05-21-2015 07:36 AM
StasyGrayn
New Contributor II

Hi all.

I'm applying filters to a few layers at runtime like this:

layer.setDefinitionExpression();

I'd like to catch the moment, when the changes has been applied (because, as it seems, they are applied with some delay).

Can anyone advise me on how can I do that?

Thanks!

Tags (2)
0 Kudos
1 Solution

Accepted Solutions
TimWitt2
MVP Alum

Hey Stasy,

do you apply this before the layer is drawn the first time or has the layer been in your map  for a while?

If it is after, you can use the update-end event, which will fire after your layer has been redrawn.

Tim

View solution in original post

3 Replies
TimWitt2
MVP Alum

Hey Stasy,

do you apply this before the layer is drawn the first time or has the layer been in your map  for a while?

If it is after, you can use the update-end event, which will fire after your layer has been redrawn.

Tim

StasyGrayn
New Contributor II

Hello, Tim!

Thanks for the answer! I was trying that event and it hasn't worked untill I was re-checking it to post here as answer. Maybe some tricky typo or anything like that.

One more thank for the fast answer

0 Kudos
TimWitt2
MVP Alum

No problem! Glad I could sorta help

0 Kudos