Please give me a sample of adding a custom tooltip to the XamWebMap MapLayer that would be attached to an .shp file and would have a TextBlock bound to a DataMapping item.
HI,
I am going to create a case for this issue and will reply to you via our CHS System.
Sincerely,
Matt Developer Support Engineer
Absolutely Great!! I love Graham's solution. I have made it work for both the Districts and the School!
Thanks much!!!
Your sample code is using the Mihail's solution and the result should be something like:
And if the mouse pointer is moved away from the TextBlock the tooltip disappears. If you apply the Graham's solution the result would be:
I have only changed the ShapeFileREaders's DataMapping to set MapElements' Caption, e.g.: DataMapping="Name, Caption=STATE_NAME"
You can move the mouse anywhere in the boundaries of the mapElement and the tooltip will be visible.
I would have attached my shape file to this but the file attach that you have is limited to 200kB. You can pick up the schooldistrict shape file for Oregon from the Census (Tiger) site for shape files.
<
="HeatMap.MainPage"
="clr-namespace:Infragistics.Silverlight.Map;assembly=Infragistics.Silverlight.DataVisualization.Map.v9.2"
>
="LayoutRoot">
="10,20,0,0">
="SchoolDistricts">
="Name=NAME;District_ID=INST_ID;County_Name=CNTY"/>
="True"/>
="8">
="Vertical">
=Name}"/>
</