ZIndex in VisualizationLayer

3 posts, 0 answers
  1. Michael
    Michael avatar
    18 posts
    Member since:
    Jul 2012

    Posted 01 Apr 2014 Link to this post

    I am trying to get specific PolygonData instances to pop to the top of a VisualizationLayer and can't seem to make it happen. I have tried settin the ZIndex on the objects as well as removing and re-adding them to the .Items collection, neither of which are successful.

    How can I do this?

    Thanks,
    Mike
  2. Andrey
    Admin
    Andrey avatar
    1681 posts

    Posted 02 Apr 2014 Link to this post

    Hi Michael,

    You should use ZIndex property of the PolygonData object. But you should also call VisualizationLayer.ArrangeItem method when you change this property. For example:

    PolygonData data = this.visualizationLayer.Items[0] as PolygonData;
    if (data != null)
    {
        data.ZIndex = data.ZIndex == 1 ? 4 : 1;
        this.visualizationLayer.ArrangeItem(data);
    }

    I hope this will help you.

    Regards,
    Andrey Murzov
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
  3. DevCraft banner
  4. Michael
    Michael avatar
    18 posts
    Member since:
    Jul 2012

    Posted 02 Jun 2014 in reply to Andrey Link to this post

    That fixed my problem. Thanks, Andrey.
Back to Top