Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.setup
external usenet poster
 
Posts: 211
Default How to change cases from small to capital in all cells?

I have to change the case of all characters from small to Capital in all
cells of an excel file (Excel 2003 and lower).
MS Word has a command called: Change case, which changes the case of
selected letters from Capital to small and vise versa. Is there any
equivalent of this command in Excel? I couldnt find it. If there is not,
what is the fastest way to change all letters from small to Capital in Excel?
If there is any Macro or VBA solution, please let me know.
One way might be to Copy/paste to word, do the change and return.


--
Rasoul Khoshravan Azar
Kobe University, Kobe, Japan
  #2   Report Post  
Posted to microsoft.public.excel.setup
external usenet poster
 
Posts: 2,646
Default How to change cases from small to capital in all cells?

Try this macro:
Sub chtocaps()
For Each cell In ActiveSheet.UsedRange
cell.Value = UCase(cell.Value)
Next cell
End Sub

Regards,
Stefi


€˛Khoshravan€¯ ezt Ć*rta:

I have to change the case of all characters from small to Capital in all
cells of an excel file (Excel 2003 and lower).
MS Word has a command called: Change case, which changes the case of
selected letters from Capital to small and vise versa. Is there any
equivalent of this command in Excel? I couldnt find it. If there is not,
what is the fastest way to change all letters from small to Capital in Excel?
If there is any Macro or VBA solution, please let me know.
One way might be to Copy/paste to word, do the change and return.


--
Rasoul Khoshravan Azar
Kobe University, Kobe, Japan

  #3   Report Post  
Posted to microsoft.public.excel.setup
external usenet poster
 
Posts: 211
Default How to change cases from small to capital in all cells?

Thanks for your solution. It helped me a lot. As its extension:
Is it possible to extend this Macro to do the same job for different files
(let say 14 files) inside one folder? All files have only one sheet.
If it is not possible, I can condensate all files into single file with 14
sheets. Then would it be possible to amend that Macro to perform the job for
14 sheets inside single file?
Thanks in Advance

--
Rasoul Khoshravan Azar
Kobe University, Kobe, Japan


"Stefi" wrote:

Try this macro:
Sub chtocaps()
For Each cell In ActiveSheet.UsedRange
cell.Value = UCase(cell.Value)
Next cell
End Sub

Regards,
Stefi


€˛Khoshravan€¯ ezt Ć*rta:

I have to change the case of all characters from small to Capital in all
cells of an excel file (Excel 2003 and lower).
MS Word has a command called: Change case, which changes the case of
selected letters from Capital to small and vise versa. Is there any
equivalent of this command in Excel? I couldnt find it. If there is not,
what is the fastest way to change all letters from small to Capital in Excel?
If there is any Macro or VBA solution, please let me know.
One way might be to Copy/paste to word, do the change and return.


--
Rasoul Khoshravan Azar
Kobe University, Kobe, Japan

  #4   Report Post  
Posted to microsoft.public.excel.setup
external usenet poster
 
Posts: 22,906
Default How to change cases from small to capital in all cells?

And be prepared to have all your formulas change to values.

Use this modified version which will not affect formulas.

Sub chtocaps()
For Each cell In ActiveSheet.UsedRange
cell.Formula = UCase(cell.Formula)
Next cell
End Sub


Gord Dibben MS Excel MVP

On Mon, 18 Sep 2006 01:17:01 -0700, Stefi
wrote:

Try this macro:
Sub chtocaps()
For Each cell In ActiveSheet.UsedRange
cell.Value = UCase(cell.Value)
Next cell
End Sub

Regards,
Stefi


„Khoshravan” ezt ķrta:

I have to change the case of all characters from small to Capital in all
cells of an excel file (Excel 2003 and lower).
MS Word has a command called: Change case, which changes the case of
selected letters from Capital to small and vise versa. Is there any
equivalent of this command in Excel? I couldn’t find it. If there is not,
what is the fastest way to change all letters from small to Capital in Excel?
If there is any Macro or VBA solution, please let me know.
One way might be to Copy/paste to word, do the change and return.


--
Rasoul Khoshravan Azar
Kobe University, Kobe, Japan


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
Linking Groups of cells between workbooks vnacj-joe Excel Discussion (Misc queries) 4 June 14th 07 05:18 PM
Change the right click menu on cells with imported data? Beth Trainer Excel Worksheet Functions 0 December 8th 05 06:43 PM
Can I change a cell and cause an automatic change in other cells Swissmiss Excel Worksheet Functions 2 August 12th 05 05:00 PM
How do I change a column of cells to all capital letters? morpattyjo Excel Worksheet Functions 4 March 13th 05 07:59 PM
How to get excel cells to change colors depending on value KV Excel Worksheet Functions 2 November 25th 04 09:50 AM


All times are GMT +1. The time now is 03:23 AM.

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"