Skip to Content
Oct 03, 2014 at 01:49 PM

AttachToComposite function



did one of you folks already had the chance to use the AttachToComposite function?

AttachToComposite(ByVal Symbol As

BaseObject) As BaseObject

This method searches in the diagram for a

composite symbol at the position of the center of the symbol specified as first

parameter and moves the symbol inside the composite symbol. In case of success,

this method returns the composite symbol.

Did it worked for you?

According to the description, this should move the symbol inside a composide symbol, if the symbol is at the coenter of the underlaying symbol ... but it doesn't work for me.

This is what I'm doing:

1. I'm creating a symbol on the diagram:

set L2ProcessSymbol = L2EAMModel.CityPlanningDiagrams.Item(0).AttachObject(L2Process)

2. I'm creating the second symbol on the diagram

set L2SubProcessSymbol = L2EAMModel.CityPlanningDiagrams.Item(0).AttachObject(L2SubProcess)

3. I'm repositioning the second symbol, so that it exactly in the center of the first symbol

ProcessXAxis = L2ProcessSymbol.Position.X

ProcessYAxis = L2ProcessSymbol.Position.Y

L2SubProcessSymbol.Position = NewPoint(ProcessXAxis,ProcessYAxis)

4. I'm calling AttachToComposite for L2SubProcessSymbol


Nothing happens.

Anz ideas?