0

I want to create a polyline in MapInfo Pro by using the snap to nodes function, which I can do.

But what I am interested to know is that when a node is added to the polyline, could any of the underlying data attributes/fields of the node that was snapped to (eg ID) be captured into the new Mapinfo table that is being created?

  • What should happen if you snap to multiple objects with difference ID's? – Peter Horsbøll Møller Apr 7 '17 at 10:35
1

There is no in-built way of doing this AFAIK, however you could use MapBasic to develop a custom drawing tool that would provide this functionality.

It should be noted that this would not be a foolproof method of picking up the actual snapped-to node in the case of having multiple selectable background layers. Unfortunately there is no functionality to return the snapped-to layer or object, you would have to search the locality (within a small tolerance) of the click location for any underlying objects. Where multiple objects are returned you would have to find a way to identifying which one you wanted to use for the attribute information.

If you do want to do this, a good start would be to look up ToolButton, CommandInfo, SearchPoint and SearchInfo in the MapBasic User Guide.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.