ActiveSheet.Shapes.Range(Array("Rounded Rectangle 2")).Visible = Not ActiveSheet.Shapes.Range(Array("Rounded Rectangle 2")).Visible
ActiveSheet.Shapes.Range(Array("Rounded Rectangle 3")).Visible = Not ActiveSheet.Shapes.Range(Array("Rounded Rectangle 3")).Visible
ActiveSheet.Shapes.Range(Array("Rounded Rectangle 4")).Visible = Not ActiveSheet.Shapes.Range(Array("Rounded Rectangle 4")).Visible
ActiveSheet.Shapes.Range(Array("Rounded Rectangle 5")).Visible = Not ActiveSheet.Shapes.Range(Array("Rounded Rectangle 5")).Visible
This is the sample of code macro that i use
i want to know how we can on run this code to hide only rectangle 1 line
like
For i = 1 To ActiveSheet.Shapes.Count
ActiveSheet.Shapes.Range(Array("Rounded Rectangle *")).Visible = _
Not ActiveSheet.Shapes.Range(Array("Rounded Rectangle *")).Visible
Next i
I just dont know how to simplify correctly