We use the ArcGIS SDK for Qt to display nautical maps from a WMS Server. On top of the actual map, we have a MessageGroupLayer for mil2525c messages. The messages are rendered just fine, but how do i query them? For example i want to enable the user to click on a message on the map to get more Information about it. How do i do that?
How do i get a message at or near a certain location?
Solved! Go to Solution.
Hi Johannes,
Once you start sending messages into the MessageGroupLayer, a new GraphicsLayer is created for the different geometry types. The MessageGroupLayer then becomes basically a GroupLayer of GraphicsLayers. What you can do is get the individual layer out of the MessageGroupLayer with GroupLayerBase::getLayers, then static_cast the one you want to GraphicsLayer. Once you have a GraphicsLayer, you can call graphicIds, and pass in your screen coordinates from a mouse click event, and it will return a list of graphic IDs that you clicked near.
- Luke
Hi Johannes,
Once you start sending messages into the MessageGroupLayer, a new GraphicsLayer is created for the different geometry types. The MessageGroupLayer then becomes basically a GroupLayer of GraphicsLayers. What you can do is get the individual layer out of the MessageGroupLayer with GroupLayerBase::getLayers, then static_cast the one you want to GraphicsLayer. Once you have a GraphicsLayer, you can call graphicIds, and pass in your screen coordinates from a mouse click event, and it will return a list of graphic IDs that you clicked near.
- Luke