1
votes

I am creating a windows phone 7.1 app and I am trying to set an image over an map. So I managed to create the map view and it is working, and I set an image over it (I am using a grid control, and I have given both the map and the image Grid.row = 0 in my XAML code, so they appear one above the other). The problem is that because the image is on top of the map, I can not click or tap or drag the map. I guess the image is catching the onclick event and it is blocking it from reaching the map.

Any ideas how to make the map accessable? Is the grid the rigth thing to use when stacking things one over the other?

Thanks!

1

1 Answers

1
votes

You should try to set the IsHitTestVisible property of the Image to false:

<Image IsHitTestVisible="False">

From MSDN:

If this property is set to false, a UIElement will not report any input events, such as MouseLeftButtonDown, and cannot receive focus. A routed input event that was originated by a different object can still route to or through an object in the object tree where IsHitTestVisible is false. The object where IsHitTestVisible is false can choose to handle that event, or can leave it unhandled so that it routes further up the object tree.