View Single Post
 
Old 10-25-2012, 05:48 PM
grizz grizz is offline Windows XP Office 2003
Novice
 
Join Date: Jan 2012
Posts: 28
grizz is on a distinguished road
Default

this will work but I'm sure some one can shorten it for you
Code:
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Cells.Count > 1 Or Target.HasFormula Then Exit Sub
If Not Intersect(Target, Range("A:A")) Is Nothing Then
    Application.EnableEvents = False
    Target.Value = UCase(Target.Value)
    Application.EnableEvents = True
ElseIf Not Intersect(Target, Range("B:B")) Is Nothing Then
    Application.EnableEvents = False
     Target.Value = UCase(Target.Value)
    Application.EnableEvents = True
    ElseIf Not Intersect(Target, Range("C:C")) Is Nothing Then
    Application.EnableEvents = False
     Target.Value = UCase(Target.Value)
    Application.EnableEvents = True
 ElseIf Not Intersect(Target, Range("D:D")) Is Nothing Then
    Application.EnableEvents = False
     Target.Value = UCase(Target.Value)
    Application.EnableEvents = True
 ElseIf Not Intersect(Target, Range("M:M")) Is Nothing Then
    Application.EnableEvents = False
     Target.Value = UCase(Target.Value)
    Application.EnableEvents = True
End If
End Sub
Reply With Quote