Add Image to a polygon and resize RRS feed

  • Question

  • Hello experts,

    I hope you can help me out with what I am trying to do.

    I am adding a polygon on the fly and trying to add an image to fill up the entire polygon using the VEShape.SetCustomIcon method. That all works fine. The image that I am adding can be of any size, so to fit it into the polygon I am getting width and height of the polygon using the pixel values from VEMap.LatLongToPixel and assigning that to the CustomIcon.

    But when the map's zoom level changes the Image does not resize. Is there any other way to resize the image other than calculating the width and height again and using those values to reset the Custom Icon? I will really appreciate any help with what I am trying to do. If there is a better way to display an image inside a polygon I am all ears.


    Tuesday, October 21, 2008 8:16 PM