Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
pow835
 
Posts: n/a
Default How can I use one formula to change case on an entire worksheet?

I inherited a worksheet where some of the names are typed on all caps. Is
there an easy way to change the case on those cells without selecting each
cell individually and using the PROPER function?
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Martin
 
Posts: n/a
Default How can I use one formula to change case on an entire worksheet?

If the names are in a column, create a Proper function in a new column beside
it and copy it down. The copy the new column and paste values back over the
original.

"pow835" wrote:

I inherited a worksheet where some of the names are typed on all caps. Is
there an easy way to change the case on those cells without selecting each
cell individually and using the PROPER function?

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Gord Dibben
 
Posts: n/a
Default How can I use one formula to change case on an entire worksheet?

Easiest method is to use a macro.

Select all cells then run the macro.

Sub Proper_Case()
'David McRitchie, programming, 2003-03-07
Dim rng1 As Range, rng2 As Range, bigrange As Range
Dim cell As Range
Application.ScreenUpdating = False
Application.Calculation = xlCalculationManual
On Error Resume Next
Set rng1 = Intersect(Selection, _
Selection.SpecialCells(xlCellTypeConstants))
Set rng2 = Intersect(Selection, _
Selection.SpecialCells(xlCellTypeFormulas))
On Error GoTo 0
If rng1 Is Nothing Then
Set bigrange = rng2
ElseIf rng2 Is Nothing Then
Set bigrange = rng1
Else
Set bigrange = Union(rng1, rng2)
End If
If bigrange Is Nothing Then
MsgBox "All cells in range are EMPTY"
GoTo done
End If
For Each cell In bigrange
cell.Formula = Application.Proper(cell.Formula)
Next cell
done:
Application.Calculation = xlCalculationAutomatic
Application.ScreenUpdating = True
End Sub


Gord Dibben MS Excel MVP

On Tue, 4 Apr 2006 08:05:02 -0700, pow835
wrote:

I inherited a worksheet where some of the names are typed on all caps. Is
there an easy way to change the case on those cells without selecting each
cell individually and using the PROPER function?


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
how to use spellnumber formula Aarif Excel Worksheet Functions 3 February 27th 06 04:36 PM
VBA Monty Excel Worksheet Functions 2 January 30th 06 01:37 PM
VBA Code Cell Mate Excel Discussion (Misc queries) 4 January 9th 06 08:52 PM
I NEED HELP with the SPELLNUMBER Function vag Excel Worksheet Functions 0 June 21st 05 08:17 AM
EXCEL:NUMBER TO GREEK WORDS vag Excel Worksheet Functions 1 June 15th 05 05:57 PM


All times are GMT +1. The time now is 05:45 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"