Format the shapes
Range("F13").Select
ActiveSheet.Shapes.AddConnector(msoConnectorStraight, 131.25, 106.5, _
316.8750393701, 170.25).Select
Selection.ShapeRange.Line.EndArrowheadStyle = msoArrowheadTriangle
Selection.ShapeRange.ConnectorFormat.BeginConnect ActiveSheet.Shapes( _
"Rectangle 3"), 3
Sub Ensure_Shape_Exists_Or_Not_In_A_Defined_Range()
Dim shp As Shape
Dim Rng As Range
Set r = Range("A1:H20")
For Each shp In ActiveSheet.Shapes
If Not Intersect(Range(shp.TopLeftCell, shp.BottomRightCell), Rng) Is Nothing Then
shp.Select
shp.Delete
Next
End Sub
Sub Find_The_Top_Right_Cell_Address_Of_Rectangle_Shape()
Dim sh As Worksheet
Set sh = ActiveSheet
Dim shap As Shape
Set shap = sh.Shapes("Rect1")
shap.Select
Dim Rng As Range
Set Rng = Cells(shap.TopLeftCell.Row, shap.BottomRightCell.Column)
MsgBox Rng.Address
End Sub
Sub Find_Begin_Connected_Shape_Name_And_End_Connected_ShapeName()
Dim ArrowConnector As Shape
Dim shp As Shape
For Each shp In ActiveSheet.Shapes
MsgBox shp.Name
If shp.Connector = True Then
Set ArrowConnector = ActiveSheet.Shapes(shp.Name)
MsgBox ArrowConnector.Name
MsgBox ArrowConnector.ConnectorFormat.BeginConnectedShape.Name
MsgBox ArrowConnector.ConnectorFormat.EndConnectedShape.Name
If shp.ConnectorFormat.BeginConnectedShape.Name = "Rect 11" Then
MsgBox "Identified the Shape"
End If
If InStr(ArrowConnector.ConnectorFormat.BeginConnectedShape.Name, "Rect") > 0 Then
Exit For
End If
Exit For
End If
Next shp
End Sub
ActiveSheet.Shapes.Range(Array("Rect11")).Select Selection.ShapeRange.IncrementLeft 10 Selection.ShapeRange.IncrementTop 50