Glue lost on connector endpoint

M

Michael Swan

I'm using the Visio automation features through the Visio 10 C++ SDK
in VC++ 6.0.

I've sucessfully connected two 2-D shapes through the use of a connector.
The endpoints of the connector at glued to each shape via GlueToPos().

However, I want to recreate my own routing on the connector rather than
using the default routing. To this end, I delete all the rows except the
first in the Geometry 1 section, then manually add rows using AddRow(), then
fill in the X and Y cells for each new "bend" in the connector. This all
works fine and the resulting diagram looks exactly right.

However, although the rerouted connector's endpoint is exactly repositioned
on the glue point of the target shape (created with the original GlueToPos()
call), that endpoint is no longer glued to the target shape. Visio still
knows about the glue point on the target shape (a little x is still present
on the target shape.)

Is there some trick/workaround to have the glue reappear on the connector
endpoint so that it's once again glued to the target shape?

Michael Swan
Neon Software, Inc.
 
M

Michael Swan

I'm using the Visio automation features through the Visio 10 C++ SDK
in VC++ 6.0.

I've sucessfully connected two 2-D shapes through the use of a connector.
The endpoints of the connector at glued to each shape via GlueToPos().

However, I want to recreate my own routing on the connector rather than
using the default routing. To this end, I delete all the rows except the
first in the Geometry 1 section, then manually add rows using AddRow(), then
fill in the X and Y cells for each new "bend" in the connector. This all
works fine and the resulting diagram looks exactly right.

However, although the rerouted connector's endpoint is exactly repositioned
on the glue point of the target shape (created with the original GlueToPos()
call), that endpoint is no longer glued to the target shape. Visio still
knows about the glue point on the target shape (a little x is still present
on the target shape.)

Is there some trick/workaround to have the glue reappear on the connector
endpoint so that it's once again glued to the target shape?

In case anyone cares, I'll answer my own question. We solved the
problem by brute force: we called GlueToPos() again to reattach
the glue to the target shape.

Michael Swan
Neon Software, Inc.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top