| 
    
     |  | ▼GOOD さん: 
 >上記の3番の「コネクタであれば、BeginかEndのShapeが該当のShapeか判定」
 >というのが、どうしてもわかりません。
 >
 >どのように判断をすればよいのでしょうか?
 >恐らくそれが出来れば、4番も自然に出来ると思います。
 
 ちょっと長いですが、
 .Connector.ConnectorFormat.BeginConnectedShape がBeginのオブジェクトになります。
 
 コネクタの付いている図形をひとつ、選択した状態で実行してみてください。
 
 Sub Test_Connector()
 Dim Tgt_Shp As Object
 Dim obj_Shp As Shape
 
 Set Tgt_Shp = Selection
 
 For Each obj_Shp In ActiveSheet.Shapes
 With obj_Shp
 If .Connector Then 'コネクタか?
 With .ConnectorFormat
 If .BeginConnected And .EndConnected Then
 If Tgt_Shp.Name = .BeginConnectedShape.Name Then  'Beginが対象か?
 Debug.Print .EndConnectedShape.Name
 ElseIf Tgt_Shp.Name = .EndConnectedShape.Name Then 'Endが対象か?
 Debug.Print .BeginConnectedShape.Name
 End If
 End If
 End With
 End If
 End With
 Next
 
 Set Tgt_Shp = Nothing
 End Sub
 
 |  |