GoXam Link Spots

I have set the entire node boundry as linkable.
In this case when a link is created the FromSpot and ToSpots are set to default as shown below.

If I move one of the nodes the link attachments side changes.

Now I have changed the link spots as shown below. In this case the FromSpot and ToSpot values are changed to {1 0.79823105200571 0 0} and {0 0.841507942139092 0 0} from default.

After this if I try to move the node link remains attached to the same position.

How do I set the FromSpot and ToSpot values explicitly, as soon as the link is created? Is there any way to convert default spot values into numeric values, so that link does not change its location?

When the user draws a new link, there is a Diagram.LinkDrawn event, at which time you could set the Link.Route.FromSpot and ToSpot.

Thanks for your reply. I tried setting the FromSpot and ToSpot values. The problem is I can set it the FromSpot and ToSpot based on the enum values only. Like, Spot.TopCenter, or MiddleLeft etc. How do I explicitly set the values like {1, 0.85,0,0}?

Use one of the two Spot constructors, which takes 2 or 4 arguments in that order.