Link to home
Start Free TrialLog in
Avatar of bhomass
bhomass

asked on

Can't get the diamond shape in UML Composition (aggregation) shape in Visio

has any one had this problem. I am using UML shapes in Visio. I tried both Visio 2000 and 2003. In both cases, the composition shape (which MS name for UML aggregation) comes out as a line with no head and end shape. I used format line and chose a number of different ending shapes. they show up in preview, but nothing gets applied to the shape on the page.

did I do something wrong? any one had better luck?
Avatar of Scott Helmers
Scott Helmers
Flag of United States of America image

The issue is probably that this is not just an arrow, but it's a smart shape with various UML-related attributes programmed into it.

For example, if I open the shapesheet (a background data sheet that drives the behavior of the shape), the head of the arrow is preset to show a diamond (the "composite" symbol) and the end of the arrow is preset with the GUARD() formula, which prevents you from changing it through the normal user interface (you've already seen that this works!).

However, you can affect the presentation of the arrow in two ways:
  1. double-click the arrow, which opens a special dialog containing UML Association properties; in this dialog you can change the label at the ends of the arrow and indicate whether the aggregation at each end is shared, composite or none; you can change other properties here as well.
  2. right-click the shape and select Shape Display Options from the right-click menu
Let me know whether this helps.

Avatar of bhomass
bhomass

ASKER

I was able to open the shapesheet. it has a lot of grids and formula. I am not able to make much sense out of it.

now when you say "double-click the arrow", I am already lost. the composition shape which I load onto the page does not any ending, so there is no arrow for me to double click. where do you say I should click?
Sorry to confuse the issue by mentioning the shapesheet -- I wasn't suggesting that you needed to look at it, only that I had looked at it as part of figuring out what was going on.

Re double-clicking the arrow -- I guess we need to confirm that we're talking about the same shape. When I drag the shape called Composition onto the page, it looks like the shape below.
...I accidentally sent the previous message before I was finished...

In the graphic below #1 is the composition shape; #2 is the result when I double-click on the arrow; #3 is the result of right-clicking and selecting Shape Display Options

Is this what you see?

Composition.jpg
Avatar of bhomass

ASKER

ok, so my visio is not behaving properly. when I drag the composition shape to the canvas, I get just a line, with no diamond head at all. And this happens on all three computers that I tried. I have two versions of visio, 2001 and 2003.

that is my question. why does it happen to me? anything I can be doing wrong?
It's possible that the default settings for this shape are different on your PCs. There are a couple of ways the defaults could have been changed, but let's not worry about that. Let's see whether the shape is still working the way it's intended to...

If you double-click on the line, does dialog #2 above appear? If so, can you change the attributes? For example, click into the column labeled Aggregation for End1, then use the dropdown list to change the value to composite. When you click OK the diamond should appear. Does it?
One other question -- if you click Help/About what version number does Visio show?
Avatar of bhomass

ASKER

no, double clicking the line, nothing happens.

on help about, it says visio standard 2003.

what I don't understand is, I have a visio 2001 installed on another computer, and it is doing the same thing, no diamond ends. double click does nothing. there is something consistent about the way I ended up with this configuration.
It's hard to guess how your PCs were set up or what might have happened afterwards.

However, I would suggest reinstalling Visio to see whether that takes care of the problem. Also, be sure you have the latest service packs for Visio. The latest for Visio 2003 is SP3
     http://www.microsoft.com/downloads/details.aspx?FamilyID=E25B7049-3E13-433B-B9D2-5E3C1132F206
   
Avatar of bhomass

ASKER

I have not been able to solve this problem. I think Scott for his effort. however, it would be misleading if I accept his solutions, because I don't know that they will help another person with this problem or not.

reinstalling visio did not work!
bhomass -- I never returned to this question because I never heard back whether a reinstall of Visio helped. I now understand that it didn't.

How are you creating the UML drawing?
  1. Are you selecting File/New/Software/UML Model Diagram and then dragging a Composition shape onto the page?
  2. Or are you creating another type of drawing, say a flowchart, then opening one of the UML stencils and dragging a Composition shape onto the page?
This is a very important question because if you are doing #1, the Composition shape should behave as I described in my earlier posts. However, if you are using method #2, the Composition shape will behave similar to what you described, i.e., it will have no arrowheads and doubleclicking will not present the dialogs shown above. In fact, when I drag the Composition shape onto a flowchart page and doubleclick it I get the error shown below.



UMLerror.jpg
Avatar of bhomass

ASKER

I don' t have file/new/software. apparently I don't have the software stencils as a package. although I could search of a whole collection of uml shapes.

do you know how you got your 'software' bundle?
ASKER CERTIFIED SOLUTION
Avatar of Scott Helmers
Scott Helmers
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of bhomass

ASKER

oh, mine, that's the mystery.

Thanks a lot!
Sorry I didn't think of that a year ago!!