Forcing all caps in a column

  • Thread starter Thread starter Dr. Indera
  • Start date Start date
D

Dr. Indera

hello,

i'd like to know if there is a way to force specific text cells to be all
caps, regardless of what is entered.

thank you
indera
 
Hi
that is only possible using VBA. Try the following (works for column A)

Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Cells.Count > 1 Then Exit Sub
If Intersect(Target, Me.Range("A:A")) Is Nothing Then Exit Sub
On Error GoTo CleanUp:
With Target
if .value<>"" then
Application.EnableEvents = False
.Value = UCase(.value)
end if
End With
CleanUp:
Application.EnableEvents = True
End Sub
 
Hi
yes. change the line
..Value = UCase(.value)
to
..Value = application.worksheetfunction.proper(.value)
 
Back
Top