+ Reply to Thread
Results 1 to 25 of 25

Is it possible to change and entire sheet to Upper case???

Hybrid View

  1. #1
    Registered User
    Join Date
    01-28-2007
    Posts
    2

    Is it possible to change and entire sheet to Upper case???

    Hi,

    Is it possible to change and entire sheet to Upper case using the 'Upper' function?

    We are need to change all the text to caps but can only seem to apply the function to one cell at a time and then copy it down for the column. This is going to be a fairly labour intensive process as we have many columns. Is there an easier way to achieve this.

    Thanks in advance

    Timbo

  2. #2
    Forum Contributor
    Join Date
    03-13-2005
    Posts
    6,195
    Quote Originally Posted by timbo105
    Hi,

    Is it possible to change and entire sheet to Upper case using the 'Upper' function?

    We are need to change all the text to caps but can only seem to apply the function to one cell at a time and then copy it down for the column. This is going to be a fairly labour intensive process as we have many columns. Is there an easier way to achieve this.

    Thanks in advance

    Timbo
    Hi,

    you did not say how many columns, but

    If you have columns A to Z
    then in AA1 put

    =Proper(A1)

    or =Upper(A1)

    and formula-fill that sideways as far as your columns go, then
    with those cells still highlighted
    formula fill downwards to the end of your data.

    Select the whole Data (AllData is click to the left of the column header, above the row numbers, the whole sheet is selected) Copy, and Paste Special = Values.

    Delete columns A to Z, then columns AA to AZ become your new A to Z

    Let me know how you go.
    ---
    Si fractum non sit, noli id reficere.

  3. #3
    Forum Expert
    Join Date
    12-29-2004
    Location
    Michigan, USA
    MS-Off Ver
    2013
    Posts
    2,208
    If you would rather not use formulas, you could right-click on the sheet tab, select view code, and paste this code, and then run the macro:
    Sub allcaps()
        Dim rng As Range, cell As Range
        Set rng = ActiveSheet.UsedRange
        For Each cell In rng.Cells
            cell.Value = UCase(cell.Value)
        Next
    End Sub

  4. #4
    Registered User
    Join Date
    01-28-2007
    Posts
    2
    Thanks Bryan and Jason.

    Jason, that macro is great. Thats going to save us heaps of work.


    Thanks very much for your help. All the best for the year ahead.

    Timbo

  5. #5
    Forum Expert
    Join Date
    12-29-2004
    Location
    Michigan, USA
    MS-Off Ver
    2013
    Posts
    2,208
    Glad I could help, Timbo.

  6. #6
    Registered User
    Join Date
    08-07-2012
    Location
    Ocala, Florida
    MS-Off Ver
    Excel 2007
    Posts
    1

    Re: Is it possible to change and entire sheet to Upper case???

    That is awesome! I have been trying for EVER to do this with different formulas...and it two seconds the code you posted took care of my whole sheet. Why haven't MicroSoft people figured out a way to simplify this for the user yet?? Ugh. Anyway..thanks so much for posting.

  7. #7
    Registered User
    Join Date
    01-15-2015
    Location
    milwaukee wi
    MS-Off Ver
    2010
    Posts
    1

    Re: Is it possible to change and entire sheet to Upper case???

    This worked great! Thanks!

  8. #8
    Registered User
    Join Date
    09-24-2021
    Location
    United States
    MS-Off Ver
    Microsoft 365 Apps for enterprise
    Posts
    7

    Re: Is it possible to change and entire sheet to Upper case???

    Thank you so much for this macro!! This made a WORLD of difference for a work project of mine.

  9. #9
    Registered User
    Join Date
    04-18-2023
    Location
    istanbul
    MS-Off Ver
    have no clue
    Posts
    1

    Re: Is it possible to change and entire sheet to Upper case???

    You. Are. A. Genius! Thank you!!!

  10. #10
    Registered User
    Join Date
    10-17-2023
    Location
    UAE
    MS-Off Ver
    2016
    Posts
    1

    Re: Is it possible to change and entire sheet to Upper case???

    thanks a ton, this saved my time and did help me a lot and many thanks once again

  11. #11
    Registered User
    Join Date
    12-20-2023
    Location
    Bahrain
    MS-Off Ver
    M365
    Posts
    1

    Re: Is it possible to change and entire sheet to Upper case???

    Thanks Jason, your Macro saved me. I was looking for many days to convert the whole sheet in Caps but could not find any. Your macro has resolved my problem, thanks a lot.

  12. #12
    Registered User
    Join Date
    12-17-2013
    Location
    California
    MS-Off Ver
    Excel 2010
    Posts
    1

    Re: Is it possible to change and entire sheet to Upper case???

    Jason: A million thanks for the Macro! You just saved me soooo much time!

  13. #13
    Registered User
    Join Date
    06-16-2014
    Location
    London
    MS-Off Ver
    2010
    Posts
    1

    Re: Is it possible to change and entire sheet to Upper case???

    Do you have this macro for lower case. I would be very grateful. Thanks

  14. #14
    Valued Forum Contributor Blake 7's Avatar
    Join Date
    10-01-2010
    Location
    Bogota, Colombia
    MS-Off Ver
    Excel 2010 64 bit and Excel 2007,
    Posts
    1,377

    Re: Is it possible to change and entire sheet to Upper case???

    Simply change UCase to LCase

    Sub allcaps()
    Dim rng As Range, cell As Range
    Set rng = ActiveSheet.UsedRange
    For Each cell In rng.Cells
    cell.Value = LCase(cell.Value)
    Next
    End Sub
    Blake 7

    If your question has been answered, please click EDIT in your original post, click GO ADVANCED and set the PREFIX box to SOLVED.

    If any member's response has helped to solve your problem, please consider using the scales icon on the top right of their post to show your appreciation.

    http://failblog.org/

  15. #15
    Registered User
    Join Date
    07-16-2014
    Location
    Georgia
    MS-Off Ver
    2010
    Posts
    2

    Re: Is it possible to change and entire sheet to Upper case???

    Hi,

    Is it possible with this macro to change the case to the Proper format? Just like the PROPER formula works on a cell? First letter is capitalized after any character other than a letter? Thanks!

  16. #16
    Forum Contributor stephenloky's Avatar
    Join Date
    07-10-2013
    Location
    Sao Paulo - Brazil
    MS-Off Ver
    Excel 2007
    Posts
    146

    Re: Is it possible to change and entire sheet to Upper case???

    Quote Originally Posted by bvfd42 View Post
    Hi,

    Is it possible with this macro to change the case to the Proper format? Just like the PROPER formula works on a cell? First letter is capitalized after any character other than a letter? Thanks!
    Sub proper()
        Dim rng As Range, cell As Range
        Set rng = ActiveSheet.UsedRange
        For Each cell In rng.Cells
            cell.Value = WorksheetFunction.proper(cell.Value)
        Next
    End Sub
    That should do the work!
    "The quieter you become, the more you are able to hear"

    Any reputation (*) points appreciated.

    "If you know yourself but not the enemy, for every victory gained, you will suffer defeat."

  17. #17
    Registered User
    Join Date
    07-16-2014
    Location
    Georgia
    MS-Off Ver
    2010
    Posts
    2

    Re: Is it possible to change and entire sheet to Upper case???

    Genius! Thank you so much!!

  18. #18
    Registered User
    Join Date
    04-02-2015
    Location
    indiana, united states
    MS-Off Ver
    2010
    Posts
    1

    Re: Is it possible to change and entire sheet to Upper case???

    just a quick question (with probably a simple answer)
    i want to change an entire worksheet to proper case (which is done with the code you posted, but i also have some columns that will have formulas in them. when you change a worksheet to proper, if you dont omit cells that have formulas in them they will change to text (or numbers), but i need to keep the formula intact. any help would be greatly appreciated.
    thanks. jake

    Quote Originally Posted by stephenloky View Post
    Sub proper()
        Dim rng As Range, cell As Range
        Set rng = ActiveSheet.UsedRange
        For Each cell In rng.Cells
            cell.Value = WorksheetFunction.proper(cell.Value)
        Next
    End Sub
    That should do the work!

  19. #19
    Forum Contributor stephenloky's Avatar
    Join Date
    07-10-2013
    Location
    Sao Paulo - Brazil
    MS-Off Ver
    Excel 2007
    Posts
    146

    Re: Is it possible to change and entire sheet to Upper case???

    Glad that you liked! Tell me if you have any questions

  20. #20
    Registered User
    Join Date
    08-08-2023
    Location
    Warwick, RI
    MS-Off Ver
    o365
    Posts
    3

    Re: Is it possible to change and entire sheet to Upper case???

    Hi I was trying to use this solution for a sheet I have, but it deleted all of my formulas.
    Is there a way to make the macro not do that?

  21. #21
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    53,048

    Re: Is it possible to change and entire sheet to Upper case???

    Quote Originally Posted by StarWars77 View Post
    Hi I was trying to use this solution for a sheet I have, but it deleted all of my formulas.
    Is there a way to make the macro not do that?
    For future reference, please start your own thread, and reference this 1 if you feel it's necessary
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  22. #22
    Valued Forum Contributor
    Join Date
    01-07-2022
    Location
    Europe
    MS-Off Ver
    Office 365
    Posts
    473

    Re: Is it possible to change and entire sheet to Upper case???

    which code were you using from above? there are a few in the thread
    <<< If you have valued anyone's contributions in this thread, please click * to thank them for their efforts

  23. #23
    Registered User
    Join Date
    08-08-2023
    Location
    Warwick, RI
    MS-Off Ver
    o365
    Posts
    3

    Re: Is it possible to change and entire sheet to Upper case???

    Sub allcaps()
    Dim rng As Range, cell As Range
    Set rng = ActiveSheet.UsedRange
    For Each cell In rng.Cells
    cell.Value = LCase(cell.Value)
    Next
    End Sub

  24. #24
    Forum Expert
    Join Date
    10-11-2021
    Location
    Netherlands
    MS-Off Ver
    365
    Posts
    1,505

    Re: Is it possible to change and entire sheet to Upper case???

    Sub jec()
     Dim it
     For Each it In ActiveSheet.UsedRange.SpecialCells(2)
       it.Value = LCase(it)
     Next
    End Sub

  25. #25
    Registered User
    Join Date
    08-08-2023
    Location
    Warwick, RI
    MS-Off Ver
    o365
    Posts
    3

    Re: Is it possible to change and entire sheet to Upper case???

    that's the ticket!
    Thank you so much!

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1