Below is a code I've tried to alter the change values in certain cells in sheets with the same prefix to proper case ...
Can anyone advise where I've gone wrong ??
Thanks
James
Public Sub Proper_Case()
Dim SH As Worksheet
Dim rng As Range
Dim rCell As Range
Set rng = ActiveWorkbook.Sheets("Control").Range(ws.Name Like "PP*")
For Each SH In ActiveWorkbook.Worksheets
If Not IsError(Application.Match(SH.Name, rng, 0)) Then
Range("B5").Select
ActiveCell = WorksheetFunction.Proper(ActiveCell.Value)
Range("I5").Select
ActiveCell = WorksheetFunction.Proper(ActiveCell.Value)
End If
Next SH
End Sub
Bookmarks