Multiple case in a spread sheet

T

Tom T

I'm have the following in VB to have the rage of cells in upper case. I want
on the same spreadsheet to have range F5:F250,G5:G250 to be PROPER case.
What do I need to add to make this happen? HELP

Private Sub Worksheet_Change(ByVal Target As Range)
Application.EnableEvents = False
If Not Application.Intersect(Target,
Range("C5:C250,H5:H250,I5:I250,J5:J250")) Is Nothing Then
Target(1).Value = UCase(Target(1).Value)
End If
Application.EnableEvents = True

End Sub
 
T

Tom Hutchins

Replace
UCase(Target(1).Value)
with
Application.WorksheetFunction.Proper(Target(1).Value)

Hope this helps,

Hutch
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top