Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1
Default How do you change the Capitalization in an Excel Workbook?

Word gives userd the ability to change the case of text to UPPER, lower &
Initial Caps...I need to standardize entries - some are lower, some are
upper, I need all entries to be Initial Caps...what do you recommend?
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,501
Default How do you change the Capitalization in an Excel Workbook?

try

=Proper(a1)

"Capitalization in Excel" wrote:

Word gives userd the ability to change the case of text to UPPER, lower &
Initial Caps...I need to standardize entries - some are lower, some are
upper, I need all entries to be Initial Caps...what do you recommend?

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 22,906
Default How do you change the Capitalization in an Excel Workbook?

You can use helper cells with the function PROPER

i.e. =PROPER(A1) entered in B1

To do a great whack at one go without a helper column you need VBA

Sub Proper()
Dim Cell As Range
Application.ScreenUpdating = False
For Each Cell In Selection
Cell.Formula = Application.Proper(Cell.Formula)
Next
Application.ScreenUpdating = True
End Sub

Sub Upper()
Dim Cell As Range
Application.ScreenUpdating = False
For Each Cell In Selection
Cell.Formula = UCase(Cell.Formula)
Next
Application.ScreenUpdating = True
End Sub


Sub Lower()
Dim Cell As Range
Application.ScreenUpdating = False
For Each Cell In Selection
Cell.Formula = LCase(Cell.Formula)
Next
Application.ScreenUpdating = True
End Sub



Gord Dibben MS Excel MVP


On Fri, 8 Aug 2008 12:12:01 -0700, Capitalization in Excel <Capitalization
in Excel @discussions.microsoft.com wrote:

Word gives userd the ability to change the case of text to UPPER, lower &
Initial Caps...I need to standardize entries - some are lower, some are
upper, I need all entries to be Initial Caps...what do you recommend?


  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1
Default How do you change the Capitalization in an Excel Workbook?

Just to add to Gord's posting...

You would use what Gord posted to fix any **existing** text already on your
worksheet. To make sure any future entries on the worksheet are in proper
case, you will need this worksheet Change event code...

Private Sub Worksheet_Change(ByVal Target As Range)
On Error GoTo Whoops
Application.EnableEvents = False
Target.Value = StrConv(Target.Value, vbProperCase)
Whoops:
Application.EnableEvents = True
End Sub

As written, it applies to the entire worksheet but it can be restricted to
smaller ranges if need be. To install the code, right click the tab of the
worksheet you want this to apply to, select View Code from the popup menu
that appears and copy/paste the above code into the code window that
appeared.

Rick


"Gord Dibben" <gorddibbATshawDOTca wrote in message
...
You can use helper cells with the function PROPER

i.e. =PROPER(A1) entered in B1

To do a great whack at one go without a helper column you need VBA

Sub Proper()
Dim Cell As Range
Application.ScreenUpdating = False
For Each Cell In Selection
Cell.Formula = Application.Proper(Cell.Formula)
Next
Application.ScreenUpdating = True
End Sub

Sub Upper()
Dim Cell As Range
Application.ScreenUpdating = False
For Each Cell In Selection
Cell.Formula = UCase(Cell.Formula)
Next
Application.ScreenUpdating = True
End Sub


Sub Lower()
Dim Cell As Range
Application.ScreenUpdating = False
For Each Cell In Selection
Cell.Formula = LCase(Cell.Formula)
Next
Application.ScreenUpdating = True
End Sub



Gord Dibben MS Excel MVP


On Fri, 8 Aug 2008 12:12:01 -0700, Capitalization in Excel <Capitalization
in Excel @discussions.microsoft.com wrote:

Word gives userd the ability to change the case of text to UPPER, lower &
Initial Caps...I need to standardize entries - some are lower, some are
upper, I need all entries to be Initial Caps...what do you recommend?



  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,501
Default How do you change the Capitalization in an Excel Workbook?

hi,

And just to add to Ricks' post I wouldn't do this if there are any formula
on your sheet because they will be converted to values.

You could modify it thus

Private Sub Worksheet_Change(ByVal Target As Range)
On Error GoTo Whoops
Application.EnableEvents = False
If Not Target.HasFormula Then
Target.Value = StrConv(Target.Value, vbProperCase)
End If
Whoops:
Application.EnableEvents = True
End Sub

Mike

"Rick Rothstein (MVP - VB)" wrote:

Just to add to Gord's posting...

You would use what Gord posted to fix any **existing** text already on your
worksheet. To make sure any future entries on the worksheet are in proper
case, you will need this worksheet Change event code...

Private Sub Worksheet_Change(ByVal Target As Range)
On Error GoTo Whoops
Application.EnableEvents = False
Target.Value = StrConv(Target.Value, vbProperCase)
Whoops:
Application.EnableEvents = True
End Sub

As written, it applies to the entire worksheet but it can be restricted to
smaller ranges if need be. To install the code, right click the tab of the
worksheet you want this to apply to, select View Code from the popup menu
that appears and copy/paste the above code into the code window that
appeared.

Rick


"Gord Dibben" <gorddibbATshawDOTca wrote in message
...
You can use helper cells with the function PROPER

i.e. =PROPER(A1) entered in B1

To do a great whack at one go without a helper column you need VBA

Sub Proper()
Dim Cell As Range
Application.ScreenUpdating = False
For Each Cell In Selection
Cell.Formula = Application.Proper(Cell.Formula)
Next
Application.ScreenUpdating = True
End Sub

Sub Upper()
Dim Cell As Range
Application.ScreenUpdating = False
For Each Cell In Selection
Cell.Formula = UCase(Cell.Formula)
Next
Application.ScreenUpdating = True
End Sub


Sub Lower()
Dim Cell As Range
Application.ScreenUpdating = False
For Each Cell In Selection
Cell.Formula = LCase(Cell.Formula)
Next
Application.ScreenUpdating = True
End Sub



Gord Dibben MS Excel MVP


On Fri, 8 Aug 2008 12:12:01 -0700, Capitalization in Excel <Capitalization
in Excel @discussions.microsoft.com wrote:

Word gives userd the ability to change the case of text to UPPER, lower &
Initial Caps...I need to standardize entries - some are lower, some are
upper, I need all entries to be Initial Caps...what do you recommend?






  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,501
Default How do you change the Capitalization in an Excel Workbook?

I should have said if you enter any NEW formula in your sheet they will be
converted to values.

"Mike H" wrote:

hi,

And just to add to Ricks' post I wouldn't do this if there are any formula
on your sheet because they will be converted to values.

You could modify it thus

Private Sub Worksheet_Change(ByVal Target As Range)
On Error GoTo Whoops
Application.EnableEvents = False
If Not Target.HasFormula Then
Target.Value = StrConv(Target.Value, vbProperCase)
End If
Whoops:
Application.EnableEvents = True
End Sub

Mike

"Rick Rothstein (MVP - VB)" wrote:

Just to add to Gord's posting...

You would use what Gord posted to fix any **existing** text already on your
worksheet. To make sure any future entries on the worksheet are in proper
case, you will need this worksheet Change event code...

Private Sub Worksheet_Change(ByVal Target As Range)
On Error GoTo Whoops
Application.EnableEvents = False
Target.Value = StrConv(Target.Value, vbProperCase)
Whoops:
Application.EnableEvents = True
End Sub

As written, it applies to the entire worksheet but it can be restricted to
smaller ranges if need be. To install the code, right click the tab of the
worksheet you want this to apply to, select View Code from the popup menu
that appears and copy/paste the above code into the code window that
appeared.

Rick


"Gord Dibben" <gorddibbATshawDOTca wrote in message
...
You can use helper cells with the function PROPER

i.e. =PROPER(A1) entered in B1

To do a great whack at one go without a helper column you need VBA

Sub Proper()
Dim Cell As Range
Application.ScreenUpdating = False
For Each Cell In Selection
Cell.Formula = Application.Proper(Cell.Formula)
Next
Application.ScreenUpdating = True
End Sub

Sub Upper()
Dim Cell As Range
Application.ScreenUpdating = False
For Each Cell In Selection
Cell.Formula = UCase(Cell.Formula)
Next
Application.ScreenUpdating = True
End Sub


Sub Lower()
Dim Cell As Range
Application.ScreenUpdating = False
For Each Cell In Selection
Cell.Formula = LCase(Cell.Formula)
Next
Application.ScreenUpdating = True
End Sub



Gord Dibben MS Excel MVP


On Fri, 8 Aug 2008 12:12:01 -0700, Capitalization in Excel <Capitalization
in Excel @discussions.microsoft.com wrote:

Word gives userd the ability to change the case of text to UPPER, lower &
Initial Caps...I need to standardize entries - some are lower, some are
upper, I need all entries to be Initial Caps...what do you recommend?



  #7   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1
Default How do you change the Capitalization in an Excel Workbook?

Thanks Mike (I think you have corrected me on this before... I don't know
why I have such a blind spot to it).

Rick


"Mike H" wrote in message
...
hi,

And just to add to Ricks' post I wouldn't do this if there are any formula
on your sheet because they will be converted to values.

You could modify it thus

Private Sub Worksheet_Change(ByVal Target As Range)
On Error GoTo Whoops
Application.EnableEvents = False
If Not Target.HasFormula Then
Target.Value = StrConv(Target.Value, vbProperCase)
End If
Whoops:
Application.EnableEvents = True
End Sub

Mike

"Rick Rothstein (MVP - VB)" wrote:

Just to add to Gord's posting...

You would use what Gord posted to fix any **existing** text already on
your
worksheet. To make sure any future entries on the worksheet are in proper
case, you will need this worksheet Change event code...

Private Sub Worksheet_Change(ByVal Target As Range)
On Error GoTo Whoops
Application.EnableEvents = False
Target.Value = StrConv(Target.Value, vbProperCase)
Whoops:
Application.EnableEvents = True
End Sub

As written, it applies to the entire worksheet but it can be restricted
to
smaller ranges if need be. To install the code, right click the tab of
the
worksheet you want this to apply to, select View Code from the popup menu
that appears and copy/paste the above code into the code window that
appeared.

Rick


"Gord Dibben" <gorddibbATshawDOTca wrote in message
...
You can use helper cells with the function PROPER

i.e. =PROPER(A1) entered in B1

To do a great whack at one go without a helper column you need VBA

Sub Proper()
Dim Cell As Range
Application.ScreenUpdating = False
For Each Cell In Selection
Cell.Formula = Application.Proper(Cell.Formula)
Next
Application.ScreenUpdating = True
End Sub

Sub Upper()
Dim Cell As Range
Application.ScreenUpdating = False
For Each Cell In Selection
Cell.Formula = UCase(Cell.Formula)
Next
Application.ScreenUpdating = True
End Sub


Sub Lower()
Dim Cell As Range
Application.ScreenUpdating = False
For Each Cell In Selection
Cell.Formula = LCase(Cell.Formula)
Next
Application.ScreenUpdating = True
End Sub



Gord Dibben MS Excel MVP


On Fri, 8 Aug 2008 12:12:01 -0700, Capitalization in Excel
<Capitalization
in Excel @discussions.microsoft.com wrote:

Word gives userd the ability to change the case of text to UPPER, lower
&
Initial Caps...I need to standardize entries - some are lower, some are
upper, I need all entries to be Initial Caps...what do you recommend?




  #8   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 22,906
Default How do you change the Capitalization in an Excel Workbook?

Or to this..........

Private Sub Worksheet_Change(ByVal Target As Range)
On Error GoTo Whoops
Application.EnableEvents = False
Target.Formula = StrConv(Target.Formula, vbProperCase)
Whoops:
Application.EnableEvents = True
End Sub


Gord

On Fri, 8 Aug 2008 17:45:19 -0400, "Rick Rothstein \(MVP - VB\)"
wrote:

Thanks Mike (I think you have corrected me on this before... I don't know
why I have such a blind spot to it).

Rick


"Mike H" wrote in message
...
hi,

And just to add to Ricks' post I wouldn't do this if there are any formula
on your sheet because they will be converted to values.

You could modify it thus

Private Sub Worksheet_Change(ByVal Target As Range)
On Error GoTo Whoops
Application.EnableEvents = False
If Not Target.HasFormula Then
Target.Value = StrConv(Target.Value, vbProperCase)
End If
Whoops:
Application.EnableEvents = True
End Sub

Mike

"Rick Rothstein (MVP - VB)" wrote:

Just to add to Gord's posting...

You would use what Gord posted to fix any **existing** text already on
your
worksheet. To make sure any future entries on the worksheet are in proper
case, you will need this worksheet Change event code...

Private Sub Worksheet_Change(ByVal Target As Range)
On Error GoTo Whoops
Application.EnableEvents = False
Target.Value = StrConv(Target.Value, vbProperCase)
Whoops:
Application.EnableEvents = True
End Sub

As written, it applies to the entire worksheet but it can be restricted
to
smaller ranges if need be. To install the code, right click the tab of
the
worksheet you want this to apply to, select View Code from the popup menu
that appears and copy/paste the above code into the code window that
appeared.

Rick


"Gord Dibben" <gorddibbATshawDOTca wrote in message
...
You can use helper cells with the function PROPER

i.e. =PROPER(A1) entered in B1

To do a great whack at one go without a helper column you need VBA

Sub Proper()
Dim Cell As Range
Application.ScreenUpdating = False
For Each Cell In Selection
Cell.Formula = Application.Proper(Cell.Formula)
Next
Application.ScreenUpdating = True
End Sub

Sub Upper()
Dim Cell As Range
Application.ScreenUpdating = False
For Each Cell In Selection
Cell.Formula = UCase(Cell.Formula)
Next
Application.ScreenUpdating = True
End Sub


Sub Lower()
Dim Cell As Range
Application.ScreenUpdating = False
For Each Cell In Selection
Cell.Formula = LCase(Cell.Formula)
Next
Application.ScreenUpdating = True
End Sub



Gord Dibben MS Excel MVP


On Fri, 8 Aug 2008 12:12:01 -0700, Capitalization in Excel
<Capitalization
in Excel @discussions.microsoft.com wrote:

Word gives userd the ability to change the case of text to UPPER, lower
&
Initial Caps...I need to standardize entries - some are lower, some are
upper, I need all entries to be Initial Caps...what do you recommend?




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
Capitalization of cells Eastee Excel Discussion (Misc queries) 2 January 17th 08 06:28 PM
Capitalization of first word in a cell Dave Excel Discussion (Misc queries) 5 April 25th 06 08:06 PM
Capitalization Patty Excel Discussion (Misc queries) 2 February 20th 06 07:29 PM
Capitalization? everlong Excel Worksheet Functions 2 February 2nd 06 01:45 AM
Capitalization shelly johnson Excel Discussion (Misc queries) 2 December 10th 05 09:23 PM


All times are GMT +1. The time now is 11:10 PM.

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

About Us

"It's about Microsoft Excel"