Thread: All Capitals
View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Gord Dibben
 
Posts: n/a
Default All Capitals

Private Sub Worksheet_Change(ByVal Target As Excel.Range)
If Target.Column 8 Then Exit Sub
On Error GoTo ErrHandler
Application.EnableEvents = False
Target.Formula = UCase(Target.Formula)
ErrHandler:
Application.EnableEvents = True
End Sub

As written, operates on Columns A:H as you enter text in a cell.

Change the 8 to whatever you wish.

This is event code and must go into the sheet module.

Right-click on the sheet tab and "View Code". Copy and paste the above into
that module.


Gord Dibben MS Excel MVP

On Tue, 13 Jun 2006 18:04:41 -0500, lostinformulas
<lostinformulas.29d5ep_1150240213.9958@excelforu m-nospam.com wrote:


Thanks,,

=Upper didn't work due to other condition in the cell


Bearacada,

Sub Uppercase()

worked perfect is there away for it to run automatically.