Creating a Custom Visio Connector

Started by Ryden, August 18, 2010, 02:42:35 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Ryden

Hi
I'm trying to make a custom connector with some special features meant for electronic schematics
I want the connector to have three custom properties, Number, Colour and Area.
I want the Number to show up at the ends and the colour to either show up as text above the connector or turn the connector to the appropriate line colour by a selection in the property menu, area is displayed under the connector.

I have tried to fiddle around and since I, ahem.. really have no clue to what I doing, obviously I've gotten nowhere
Where do I start? I tried to create a line ending which was only a text block, but couldn't connect it to my property.
Could some kind soul have mercy on me and give me a point of advice

Regards/Anders Ryden

Yacine

#1
I wish we could have an  answer configurator ... from which, one would chose the answers already posted here.
Unfortunately it is faster to write an answer than to find the right posts.

Ryden,
your question raises so much fundamental visio concepts, that I don't know where to start.

I am too tired this evening to explain this.
So please accept a shape instead of a text ;D

Yacine

Ryden

#2
Thank you Yacine!
That was great.
I added some things, but I can't seem to get it to work as a single shape, more like a group.
Is it possible go get the name of the line color somewhere, i think it would be a better idea to change line color as usual and let the property contain the name
Also I would like to link the font size of the text boxes to the connectors font size property, I can't find a way to do that.

Big Thank You/Anders

vojo

#3
Maybe something like this would help  (based on some work June did)
Rt click and double click to see behaviors


Yacine

#4
Yes,you need to use a group, but don't group the connector, rather transform it into a group (menu shapes/grouping)
Yacine

Ryden

#5
I dont have an option to Transform, I can however Convert to group.
That doesn't help though, the textboxes still don't change size together.
Text size should be a property of a shape but I can't get it. How is it done?

Ryden

#6
I think I have gotten it as close as I'm going to get to what I need
Many thanks to you all, esp. Yacine!

It's still a group, I cant' find a way to make it a single shape.
Change line color and the color name above the connector changes, font size from the connector updates the Number textboxes etc

I found this tutorial about DataFields wich would be perfect, but I assume he's talking about Visio 2010 as I can't seem to find the data menu.

I also found a reference to a function called FONTTOID(), is there something similar for colours?

When I look in the shapesheet there is a section called Text Fields which seems to indicate that there can be more than one text field to a shape, how do I add a second text field?

/Anders

aledlund

#7
the data menu started in v2007 and is available in the professional versions (and above)
al

Jumpy

#8
Quote from: Ryden on September 02, 2010, 06:50:38 AM

When I look in the shapesheet there is a section called Text Fields which seems to indicate that there can be more than one text field to a shape, how do I add a second text field?


You can have multiple fields in the one textbox a normal shape has. For Example the Text could contain Creator and CreateDate, both inserted as field.

Visio Guy

You can convert single shapes into groups using Shape > Grouping > Convert to Group.

Any geometry will still be at the group level, and on top of sub-shapes by default. But you can now open the group and put things inside. This is an essential technique for turning Visio's built-in Dynamic connector into something fancy. The geometry has to be at the top level so that Visio can re-write the vertices when it does automatic routing.
For articles, tips and free content, see the Visio Guy Website at http://www.visguy.com
Get my Visio Book! Using Microsoft Visio 2010

Ryden

O, I see! I finally got it!
Instead of grouping the shapes, convert ONLY the connector and add the textboxes
Yes that did it.
Is there a way to anchor the Controls a fixed distance from the ends, as soon as I move a Control it changes it's value to Control.X=Width*0,456 or something similar wich means it moves proportional when the connector end is moved.

Jumpy

I think thats where XDynamics and YDynamics are for.
But didn't changen them myself jet, but the could for example be set to 0mm.

RBKBrown

OK - I'm lost
there *is* no such menu ... "Shape > Grouping > Convert to Group"
where is this on "the ribbon" ?

Paul Herber

Visio 2010 - first you need to ensure developer mode is enabled (ribbon File -> Options -> General
then ribbon Developer -> Shape Design -> Group
Electronic and Electrical engineering, business and software stencils for Visio -

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

RBKBrown

Thank you Paul ... the old menu breadcrumbs nomenclature doesn't reflect the ribbon too well.
NOW: what on earth did VisGuy mean a few posts back by "now you can open up the group and put other things inside"? ... sounds good, but HOW?