Can't retrieve a connection via Formula or Glued Objects or Connector to a pool lane

Hello,

First of all thanks for the big help that ou provide us for all the Aspose products that we use (Cells,Diagram,Word,Slide…).

The Attached visio file contains 5 mains Objects :

  1. a pool lane “Customer”
  2. an Event “SL Upgrade”
  3. an operation “Analyse customer request”
  4. 2 message flows “Customer request” & “Request for service level upgrade”

Our problem is that we can’t retrieve via code the connection between the 2 message flows “Customer request” & “Request for service level upgrade” AND the pool lane “Customer”

In our code we have 3 ways to retrieve connections :

  1. We look in the “formula” of the pool lane in order to get all the connected elements. In our case the formula is useless because the indicator “1(” is empty

Shape ID : 1

Shape name : Pool / Lane.71

Shape nameU : Pool / Lane.71
Formula :SUM(DEPENDSON(5,Sheet.46!SheetRef()),DEPENDSON(1)))

  1. through the connectors we look if there is a connection between two elements. In our case there is no “Connect” point FROM or TO the pool lane “Customer”
    Connect connector : (Iterable<Connect>) vdxDiagram.getPages().get(0).getConnects()
  2. finally we look if there is a glued shapes to the element pool lane .
    long[] gluedShapeIds = shape.gluedShapes(GluedShapesFlags.GLUED_SHAPES_ALL_2_D, null, null);

None of those solutions above did help us detect the connection between the two message flows and the pool lane.

PS : we use the version 21.4.1.0


This Topic is created by asad.ali using Email to Topic tool.msgFlow.7z (178.5 KB)

@eljuventino
Would you please share the sample file and code for our reference?
We will look into it.
Thanks.

I alrready shared the example with you in the attachement file “msgFlow.7z”

@eljuventino
When you move the shape pool lane in visio, you will find that the pool lane and the shape flow are separated, and the shape flow will not move with the pool lane, so they are not linked or glued together.
When you use this samplde code,you will get the shape id 6:
Shape shape = page.getShapes().getShape(5);
long[] id2s = shape.gluedShapes(GluedShapesFlags.GLUED_SHAPES_ALL_2_D, null, null);
This means that shape id 5 means flow is only glued to shape id 6.

In the attached file, when you move the pool lane shape, the flow shape will move with it, which means they are glued together.msgFlow1.zip (225.1 KB)

Thanks.

The result of the code above mention clearly that The Flow “Customer request” with the ID: 5 is glued To the shape “Analyse customer request” with ID : 6 and in no way it is Glued to the Pool lane “Customer” with the ID : 1.
As you did experience in the Visio file attached , the pool lane (ID: 1) is indeed linked to the flow (ID:5) but there is no way that we had that information through Aspose Code using the three ways that we mentioned (Formula,Glue,Connect) .

@eljuventino
We will look it soon ,Thanks.

@eljuventino
The shape flow only appears to be at the location of the link point of the shape pool lane, but they are not actually glued together. Therefore, when you move the pool lane, the shape flow does not follow the movement, when you move the shape task 6, the shape flow will follow the movement.
So the shape flow is glued with shape task but not glued with shape pool lane.
And visio does not store information linking the two shapes of pool lane and flow.
That’s why we can’t get relevant information in page’s connects.
And we can only return shape id 6 based on visio’s information.
Thanks.

Thank you for your feedback. We did manage to “re-Connect” the flows to the pool lane and now we can get some informations throug aspose code.
Although, we still have some problems understanding the results that we had. In the Attached Visio file “msgFlowARKcreatedFlow.vsdx” the flows are connected to the pool lane(ID:1) but in the aspose code we have always the information that the flows are connected to the CFF container (ID:48).

In our application we give the user the opportunity to map the objects found in Visio (Through Aspose code) to our database Objects. For the client the pool lane is connected to the flow and It doesn’t make any sense that the connection(Through Aspose code) is between the flow and the CFF Container.
image.png (31.1 KB)

This behaviour is confusing and we are not sure if this is a bug or not.msgFlowARKcreatedFlow.7z (181.6 KB)

@eljuventino
We are looking into this scenario and will get back to you soon.
Thanks.

@eljuventino
We found that when adding a master “pool/lane” in Microsoft visio, visio will add 5 shapes at the same time, including Pool/Lane and CFF Container, we can find these two shapes in visio, among which Pool/Lane is without any link Point, the link point is in the CFF Container, so when you link the entire Pool / Lane, visio is actually linked to the cff containerCFF Container.zip (16.4 KB)
, please refer to the shapesheet of the two shapes.
Thanks.

Thank you Philip for your explanation.
It is clear that the CFF container is the one linked to the flows. What we’re looking for now is to find a link between the Pool Lane and the Flows through the CFF containers.
the flow --> CFF Container –> The poo lane
We did try to use the Formulas but there is no much informations there that the pool lane and the Cff Container are in a relationShip.
the CFF container it’s not a sub group of the Pool Lane either (the other way around it’s not working either).

To resume what we want :
In Visio, Our Client sees that the pool lane is Connected to the Flows. In Aspose code The Flows are connetd to the CFF Container. So Our final Goal is to find a Path (formula,Group…) From The flows to the Pool Lanes through the CFF Container.

@eljuventino
Please try this sample code to get depends on shapes:
long[] ids = shape.dependsOnShapes();

CFF Container depends on Swimlane List,Phase List
and Swimlane List depends on CFF Container ,Pool / Lane ,Phase List

Through these shape relationships, you can finally get the result you want.