ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Easiest way to CAPITALIZE entire worksheet ? (https://www.excelbanter.com/excel-discussion-misc-queries/97586-easiest-way-capitalize-entire-worksheet.html)

Nugget

Easiest way to CAPITALIZE entire worksheet ?
 
When I select text, the FORMAT menu & EFFECTS block does not provide an
uppercase option.

Any help will be greatly appreciated.

Lar


jetted

Easiest way to CAPITALIZE entire worksheet ?
 

Hi

This code should capitalize everything

Sub capitalize_cell()

Dim Cell As Range
Dim R As Range
Set R = ActiveSheet.UsedRange
'SearchChar = "#"
For Each Cell In R
valeur = Cell.Value
valeur = UCase(valeur)
Cell = valeur

Next
End Sub


--
jetted
------------------------------------------------------------------------
jetted's Profile: http://www.excelforum.com/member.php...o&userid=17532
View this thread: http://www.excelforum.com/showthread...hreadid=558484


Jim Cone

Easiest way to CAPITALIZE entire worksheet ?
 
The free Excel add-in "Excel Extras" will do that.
It adds options for upper, lower, sentence and proper case to the Format menu.
Does other stuff too. Download from http://www.realezsites.com/bus/primitivesoftware
--
Jim Cone
San Francisco, USA


"Nugget"
wrote in message
When I select text, the FORMAT menu & EFFECTS block does not provide an
uppercase option.

Any help will be greatly appreciated.

Lar


Gord Dibben

Easiest way to CAPITALIZE entire worksheet ?
 
Just be warned about this macro.

If there are any formulas in the used range, they will all be turned to values.

Amend to.........

Sub capitalize_cell()

Dim Cell As Range
Dim R As Range
Set R = ActiveSheet.UsedRange
For Each Cell In R
Cell.Formula = UCase(Cell.Formula)
Next
End Sub


Gord Dibben MS Excel MVP

On Wed, 5 Jul 2006 10:43:36 -0500, jetted
wrote:


Hi

This code should capitalize everything

Sub capitalize_cell()

Dim Cell As Range
Dim R As Range
Set R = ActiveSheet.UsedRange
'SearchChar = "#"
For Each Cell In R
valeur = Cell.Value
valeur = UCase(valeur)
Cell = valeur

Next
End Sub




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

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com