Select to view content in your preferred language

how to disappear graphics while zoom out..??

2159
3
Jump to solution
06-18-2012 03:40 AM
popmotsy
Emerging Contributor
I am working on application created in ArcGIS for flex, working on bookmark widget.

Now for the selected bookmark application show some graphic and text which shows selected bookmark area.

Now i want to disappear this text and graphics when zoom out from that point. Any idea or help.?
Tags (2)
0 Kudos
1 Solution

Accepted Solutions
AnthonyGiles
Honored Contributor
Pop,

Can you set the graphic and text up in an mxd with a scale dependant layer (do not show when zoomed out past) so when you zoom out it turns the graphics off

or

if the graphics are drawn in the viewer itself then on the zoom functions set the code to something
like:

on zoom out

if(map.scale > 5000)
graphicsLayer.visible = false;

on zoom in

if(map.scale < 5000)
graphicsLayer.visible = true;

Regards

Anthony

View solution in original post

0 Kudos
3 Replies
AnthonyGiles
Honored Contributor
Pop,

Can you set the graphic and text up in an mxd with a scale dependant layer (do not show when zoomed out past) so when you zoom out it turns the graphics off

or

if the graphics are drawn in the viewer itself then on the zoom functions set the code to something
like:

on zoom out

if(map.scale > 5000)
graphicsLayer.visible = false;

on zoom in

if(map.scale < 5000)
graphicsLayer.visible = true;

Regards

Anthony
0 Kudos
popmotsy
Emerging Contributor
Hi ,

Thanks for your Help...It works fine , when i set "map.scale" property in zoom functions. 😄
0 Kudos
AnthonyGiles
Honored Contributor
Pop,

Glad you got it working, don't forget to mark the post as answered

Thank you

Anthony
0 Kudos