P
Per Jessen
Hi
You are missing a single dot before cells.select to set the reference
to ws, ie it should read:
..Cells.Select
I would also skip the select statement as it slows down your code.
Sub Change_for_ALL_Worksheets()
Dim ws As Worksheet
For Each ws In ActiveWorkbook.Worksheets
With ws
'-----------------------------------------------------------------------
'.With Statement code STARTS here below:
With .Cells
.VerticalAlignment = xlCenter
End With
'.With Statement code ENDS here above.
'-----------------------------------------------------------------------
End With
Next ws
End Sub
Hopes this helps
.....
Per
You are missing a single dot before cells.select to set the reference
to ws, ie it should read:
..Cells.Select
I would also skip the select statement as it slows down your code.
Sub Change_for_ALL_Worksheets()
Dim ws As Worksheet
For Each ws In ActiveWorkbook.Worksheets
With ws
'-----------------------------------------------------------------------
'.With Statement code STARTS here below:
With .Cells
.VerticalAlignment = xlCenter
End With
'.With Statement code ENDS here above.
'-----------------------------------------------------------------------
End With
Next ws
End Sub
Hopes this helps
.....
Per