{"id":2372,"date":"2015-03-09T14:20:08","date_gmt":"2015-03-09T14:20:08","guid":{"rendered":"http:\/\/www.microsofttraining.net\/b\/?p=2372"},"modified":"2023-12-31T00:05:24","modified_gmt":"2023-12-31T00:05:24","slug":"how-to-change-case-text-in-excel","status":"publish","type":"post","link":"https:\/\/www.stl-training.co.uk\/b\/how-to-change-case-text-in-excel\/","title":{"rendered":"How to change case text in Excel"},"content":{"rendered":"<h2><strong>Quick and easy ways to change case text in Excel.<\/strong><\/h2>\n<p>You may have a list which you wish to change the case test in Excel. Rather than manually re-entering the data in Excel, there are some useful functions you can call on to save you this work. Let&#8217;s look at a few of them.<\/p>\n<p>In this example we have a list of planets\u00a0starting in lowercase and we wish to have them starting in uppercase.\u00a0Here we will use the <strong>Proper<\/strong> function.<\/p>\n<p><strong>Step 1<\/strong>\u00a0Select\u00a0the\u00a0adjacent blank cell\u00a0and type =Proper(A1)<\/p>\n<p><strong>Step 2.<\/strong>\u00a0Autofill\u00a0through to B8. You should now have a list of Planets, not planets!<\/p>\n<p><a href=\"https:\/\/www.stl-training.co.uk\/b\/wp-content\/uploads\/2015\/03\/Excel_proper_function.jpg\"><img decoding=\"async\" class=\"alignnone size-full wp-image-2401\" src=\"https:\/\/www.stl-training.co.uk\/b\/wp-content\/uploads\/2015\/03\/Excel_proper_function.jpg\" alt=\"Excel_proper_function\" width=\"385\" height=\"426\" \/><\/a><\/p>\n<p>&nbsp;<\/p>\n<p><strong>Step 3.<\/strong> To replace the original data copy the cells B1:B8 and paste as values back to A1:A8.<\/p>\n<p><strong>Step 4.<\/strong> Finally\u00a0clear the\u00a0range B1:B8.<\/p>\n<p>To turn text to upper case repeat the steps above using\u00a0 the <strong>Upper<\/strong> function instead of Proper. And, yes you guessed it, use the <strong>Lower<\/strong> function to change test all to lowercase.<\/p>\n<h3><strong>Writing a Macro to\u00a0run the Proper case function<\/strong><\/h3>\n<p>If you need to change the case of text in Excel on a routine basis, you can save even more time by automating the process with a quick macro.<\/p>\n<p>Using a blank Workbook press <strong>Alt+F11<\/strong> to go to the <strong>VBA editor<\/strong>.<\/p>\n<p><a href=\"https:\/\/www.stl-training.co.uk\/b\/wp-content\/uploads\/2015\/03\/insert_module_macro.jpg\"><img decoding=\"async\" class=\"alignnone size-full wp-image-2402\" src=\"https:\/\/www.stl-training.co.uk\/b\/wp-content\/uploads\/2015\/03\/insert_module_macro.jpg\" alt=\"insert_module_macro\" width=\"450\" height=\"307\" \/><\/a><br \/>\nInsert a\u00a0 new module and type the following 2 macros.<\/p>\n<p>Sub Proper()<br \/>\nDim cell As Range\u00a0\u00a0 &#8216;cell is a name for the range variable<br \/>\nFor Each cell In Selection<br \/>\ncell = WorksheetFunction.Proper(cell)<br \/>\nNext cell<br \/>\nEnd Sub<\/p>\n<p>Sub Upper()<br \/>\nDim cell As Range<br \/>\nFor Each cell In Selection<br \/>\ncell = UCase(cell)<br \/>\nNext cell<br \/>\nEnd Sub<\/p>\n<p>Now you can close the &#8220;Microsoft Visual Basic for Applications&#8221; window (don&#8217;t worry your macros are now saved), and return to your spreadsheet.<\/p>\n<p>Save \u00a0your spreadsheet as a Macro-Enabled\u00a0workbook called MyMacros.<\/p>\n<p>You\u00a0could use the workbook to store other macros\u00a0for use in any\u00a0workbook and assign them to buttons on the <strong>Quick Access Toolbar<\/strong>.<\/p>\n<p>Finally\u00a0hide the workbook by selecting <strong>View, Hide<\/strong> and\u00a0exit Excel saving again\u00a0as MyMacros.<\/p>\n<p>When you return to\u00a0Excel open MyMacros and add the Proper and Upper macros to the Quick Access Toolbar as follows.<\/p>\n<p>1. Click the arrow on the right of the Quick Access Toolbar.<\/p>\n<p><a href=\"https:\/\/www.stl-training.co.uk\/b\/wp-content\/uploads\/2015\/03\/more_commands_quick_access_toolbar.jpg\"><img decoding=\"async\" class=\"alignnone size-full wp-image-2403\" src=\"https:\/\/www.stl-training.co.uk\/b\/wp-content\/uploads\/2015\/03\/more_commands_quick_access_toolbar.jpg\" alt=\"more_commands_quick_access_toolbar\" width=\"543\" height=\"429\" \/><\/a><\/p>\n<p>2. Select <strong>More Commands<\/strong>.<br \/>\n3. Choose <strong>Macros<\/strong>\u00a0in the\u00a0commands from option.<br \/>\n4.\u00a0Click Proper and click Add, click Upper then <strong>Add.<\/strong><br \/>\n5. Select <strong>Modify<\/strong> to change the button images.<br \/>\n6. Change the\u00a0<strong>Display name<\/strong>.<br \/>\n6. Reposition the buttons to suit.<\/p>\n<p>Now exit Excel again and test your macros work by selecting\u00a0some text.<\/p>\n<p>The hidden MyMacros workbook automatically opens when the Proper Case button is clicked and changes the text accordingly. A press of the button and the work is done, whether for a single cell or for a large range of selected cells in any workbook,\u00a0saving you time and the risk of errors from manual data entry.<\/p>\n<p><a href=\"https:\/\/www.stl-training.co.uk\/b\/wp-content\/uploads\/2015\/03\/Propermac2.jpg\"><img decoding=\"async\" class=\"alignnone size-medium wp-image-2387\" src=\"https:\/\/www.stl-training.co.uk\/b\/wp-content\/uploads\/2015\/03\/Propermac2-253x300.jpg\" alt=\"Propermac2\" width=\"253\" height=\"300\" \/><\/a><\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Quick and easy ways to change case text in Excel. You may have a list which you wish to change the case test in Excel. Rather than manually re-entering the data in Excel, there are some useful functions you can call on to save you this work. Let&#8217;s look at a few of them. In [&hellip;]<\/p>\n","protected":false},"author":5,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[4,6],"tags":[88,90,344,436,445,557,614],"class_list":["post-2372","post","type-post","status-publish","format-standard","hentry","category-excel-training","category-hints-tips","tag-change-case-text-in-excel","tag-changing-lowercase-to-uppercase-in-excel","tag-lower-function-excel","tag-prevent-data-entry-errors-in-excel","tag-proper-function","tag-upper-function-excel","tag-write-a-macro-to-change-text-in-excel"],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/www.stl-training.co.uk\/b\/wp-json\/wp\/v2\/posts\/2372","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.stl-training.co.uk\/b\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.stl-training.co.uk\/b\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.stl-training.co.uk\/b\/wp-json\/wp\/v2\/users\/5"}],"replies":[{"embeddable":true,"href":"https:\/\/www.stl-training.co.uk\/b\/wp-json\/wp\/v2\/comments?post=2372"}],"version-history":[{"count":1,"href":"https:\/\/www.stl-training.co.uk\/b\/wp-json\/wp\/v2\/posts\/2372\/revisions"}],"predecessor-version":[{"id":6893,"href":"https:\/\/www.stl-training.co.uk\/b\/wp-json\/wp\/v2\/posts\/2372\/revisions\/6893"}],"wp:attachment":[{"href":"https:\/\/www.stl-training.co.uk\/b\/wp-json\/wp\/v2\/media?parent=2372"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.stl-training.co.uk\/b\/wp-json\/wp\/v2\/categories?post=2372"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.stl-training.co.uk\/b\/wp-json\/wp\/v2\/tags?post=2372"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}