Help- Changing Case

  • Thread starter Thread starter RoadKing
  • Start date Start date
R

RoadKing

Good morning:
Excel 2003: I need to change the case on imported data from "CAPS" to
"Proper". I thought it would have been an easy process but I was wrong. Any
help would be greatly appreciated

Thanks
John
 
Select the cells you want to make Proper and run this small macro:

Sub properize()
For Each r In Selection
r.Value = Application.WorksheetFunction.Proper(r.Value)
Next
End Sub
 
Select the cells you want to make Proper and run this small macro:
Sub properize()
For Each r In Selection
r.Value = Application.WorksheetFunction.Proper(r.Value)
Next
End Sub

Or, using "pure" VBA code...

For Each R In Selection
R.Value = StrConv(R.Value, vbProperCase)
Next

Rick
 
Just to add a caveat...............

In either case, make sure you have no cells with formulas selected.

They will be changed to values.


Gord Dibben MS Excel MVP
 
Back
Top