Link to home
Start Free TrialLog in
Avatar of Frank .S
Frank .SFlag for Australia

asked on

Excel 2010-Upper Case Letters to Every Word in Spreadsheet

Hi Experts,
I need to change the first letter of every word in my spreadsheet to upper case, is there a formula I can use to do this with 1 action or do i have to manually change each letter to upper case?
This will need to apply to each word within a spreadsheet that has around 2000 line entries
Avatar of Rgonzo1971
Rgonzo1971

Hi

Pls try on your selected cells

Sub DoUpperCase()
For Each cell In Selection
        cell.Value = WorksheetFunction.Proper(cell.Text)
Next
End Sub

Open in new window


Regards
Avatar of Frank .S

ASKER

Hi Rgonzo1971,
I have pasted this code into the worksheet, but I need a lot more directions as to what else i need to do etc?
Hi,

first select the cells you want to change then run the code, the code cannot change the result of formulas.

Regards
Hi expert, i have selected the cells but dont know how to then run the code in excel 2010?
Goto View/Macros/View Macros then you should find DoUpperCase then Click Run

Regards
Right-click on the sheet tab name
Select View code
From the menu      Insert > Module
Paste the given code in the VBA window
Close the VBA window
Press Alt-F8
Select the macro name
Click on run
If you want to do this more than once then after the "Select the macro name" in ssaqibh's steps, click the 'Option…' button and place a letter like 'z' in the 'Ctrl+' box. From then on all you need to do to run the macro is to press Ctrl+z.
Did any of the above help you?
ASKER CERTIFIED SOLUTION
Avatar of Frank .S
Frank .S
Flag of Australia image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
all expert suggestions were not what worked for me