Author Topic: smart connector text?  (Read 9779 times)

0 Members and 1 Guest are viewing this topic.

novski

  • Full Member
  • ***
  • Posts: 182
smart connector text?
« on: March 31, 2014, 07:26:55 AM »
hi
me again with some newbie questions...

I found quite a few posts that show different ways to make a connector have text on both ends. But i didn't manage to find one that does not brake when i ungroupe it and as well has text on both ends. All trough i managed to make the text be shown as shape data as i wold like it to be.
May someone help me to add the same shapedata as i have on one end to the other end?
I added a sample of my tests to the attachment. its actualy a copied sample of this tread: http://visguy.com/vgforum/index.php?topic=4689.0

best regards
novski

Paul Herber

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2955
    • Paul Herber's website
Re: smart connector text?
« Reply #1 on: March 31, 2014, 07:31:47 AM »
Shapes will almost always break when you ungroup them. Either open the group to edit it, or use the Drawing Explorer window.
Electronic and Electrical engineering, business and software stencils and applications for Visio -

https://www.paulherber.co.uk/

novski

  • Full Member
  • ***
  • Posts: 182
Re: smart connector text?
« Reply #2 on: April 01, 2014, 12:34:33 AM »
Howcome there is a text hanging on one edge of the non-grouped cable in the attachment?
Is it not possible to add a second the same way?
Best regards
Novski

Jumpy

  • Hero Member
  • *****
  • Posts: 1061
Re: smart connector text?
« Reply #3 on: April 01, 2014, 02:30:01 AM »
Every shape (and so every connector) has one internal textbox. In your attachment that textbox is placed relative to the yellow control point and that's it. To have a second textbox at the other end you need a second shape (a shape that is only a textbox) and group it together with the connector. You have to change the group behaviour to 1D so it's a connector again.

Or you search the forum for examples of connectors with textboxes on both ends. That's something that is asked for regularly, so there are some threads about that here.

novski

  • Full Member
  • ***
  • Posts: 182
Re: smart connector text?
« Reply #4 on: April 03, 2014, 02:34:48 AM »
Hi again
i had some spare hours now and searched for a sample witch fits my needs. I found one wich makes all i needed. But now i got curius about how it works and can not figure out how that text sticks to the connector...

i followed http://www.visguy.com/2009/05/06/top-twelve-text-tips/ this agian but still i don't understand how the second  text is glued to the end of the connector... (the first is declared very well..)
is there any more sufficient posts around here somewere?

i found those in this first thread but that didn't help eather..
http://visguy.com/vgforum/index.php?topic=4689.0
http://visguy.com/vgforum/index.php?topic=1651.msg7116#msg7116

all throu this is very interessting...
http://www.visguy.com/2010/03/22/1d-shape-handles-through-the-years/

thanks for some more help..

Yacine

  • Hero Member
  • *****
  • Posts: 2712
Re: smart connector text?
« Reply #5 on: April 03, 2014, 06:34:02 AM »
Here are some explanations to the shape I posted in the link you mentioned (http://visguy.com/vgforum/index.php?topic=4689.0)
Hope that suffices,
Y.
« Last Edit: April 03, 2014, 06:35:47 AM by Yacine »
Yacine

aledlund

  • Hero Member
  • *****
  • Posts: 1412
Re: smart connector text?
« Reply #6 on: April 03, 2014, 07:24:26 AM »
yacine,
a very nice description and post.
al

Jumpy

  • Hero Member
  • *****
  • Posts: 1061
Re: smart connector text?
« Reply #7 on: April 03, 2014, 08:40:48 AM »
Another trick (learned from Graham Wideman's book some years ago) to
- place textboxes or
- special line-ends or
- determine the direction in which a connector connects to a shape

is to place a connection point very near the begin and end of the connector.

If you make them part oft the inner connector inside the group, you even can make them invisible.

Whenever the connector changes his pathes, Visio will recalc the placement of that connection points and will place them near the lineends again.

So you can use the coordinates of that connection points (together with the line ends) as a base for your calculations.

Yacine

  • Hero Member
  • *****
  • Posts: 2712
Re: smart connector text?
« Reply #8 on: April 03, 2014, 11:22:17 AM »
@Jumpy, I don't see the difference between the coordinates of the endpoints and those of connection points. you can calculate with both.
Yacine

Jumpy

  • Hero Member
  • *****
  • Posts: 1061
Re: smart connector text?
« Reply #9 on: April 04, 2014, 02:04:32 AM »
You're right. The issue / trick with the connection points is, that they make it possible (together with BeginX/Y, EndX/Y) to calculate the direction your last line segment has. So you can determin if your connector connects to a shape from above, or from left or right and so it can help to place the textbox without overlapping other shapes.

novski

  • Full Member
  • ***
  • Posts: 182
Re: smart connector text?
« Reply #10 on: April 08, 2014, 08:32:13 AM »
I worked it out. Thanks for the Help.
my version in att...
cheers
novski

novski

  • Full Member
  • ***
  • Posts: 182
Re: smart connector text?
« Reply #11 on: April 15, 2014, 10:35:49 AM »
just stumled over a problem with my connector. As soon as i want a different line color it also colored the outlines of the textboxes.
Is it possible to prevent the texboxes to change linecolor in the group of my connector?
I wold need a red connector...

best regards
novski

Yacine

  • Hero Member
  • *****
  • Posts: 2712
Re: smart connector text?
« Reply #12 on: April 15, 2014, 10:53:29 AM »
Sure, select the textboxes and protect them against formating. (RMK/Format/Protection)
Or better, set in the shapesheet the Geometry.NoLine to "guard(true)"
This way you can format the text, but keep the border of the text boxes invisible.
Yacine

novski

  • Full Member
  • ***
  • Posts: 182
Re: smart connector text?
« Reply #13 on: April 17, 2014, 01:26:56 AM »
Thanks for that hint. I had to work it out. first i just selected the Connector and tried to make the Geometry.NoLine to "guard(true)" but then the connector disapieard. After a second of brainstorm i understood what you ment and whent in to the Mastershape and selected the Text boxes it self. With Geometry.NoLine to "guard(true)" of the Text box now it works.
Thanks a lot
novski

novski

  • Full Member
  • ***
  • Posts: 182
Re: smart connector text?
« Reply #14 on: April 30, 2014, 02:28:23 AM »
Hi again
i sumbled over another problem with my connector.
As soon as i connect it in a direction thats oposite the flow from startpoint to endpoint it doesn't flip it with the connector.
There is a example attached. The two flow directions that end in normal OUT to IN points its all good but as soon as i make a connection that has IN and OUT on the same direction it shows the text on the wrong side...

How can i Flip the Text to handle the Cable direction and the Flowdirection automaticaly?