How to change the first letter in Capital letter
Hi There,
Can anybody help me how to change the first letter of my item description into a capital letter, in a macro, I have more that 5000 item description that I have to be changed the first letter into a Caps so that when I sort them it will go together. It is time consuming to change it one by one. Like company to Company, name to Name, etc. Thanks for your help. Eric |
How to change the first letter in Capital letter
Hi Eric
See David's site http://www.mvps.org/dmcritchie/excel/proper.htm -- Regards Ron de Bruin (Win XP Pro SP-1 XL2000-2003) www.rondebruin.nl "Eric" wrote in message ... Hi There, Can anybody help me how to change the first letter of my item description into a capital letter, in a macro, I have more that 5000 item description that I have to be changed the first letter into a Caps so that when I sort them it will go together. It is time consuming to change it one by one. Like company to Company, name to Name, etc. Thanks for your help. Eric |
How to change the first letter in Capital letter
you can loop the data so it will fit your layout but I would use
something like Dim strTemp As String Dim i As Integer i = 0 Do Until Trim(Range("A1").Offset(i, 0).Value) = "" strTemp = Trim(Range("A1").Offset(i, 0).Value) strTemp = Left(UCase(strTemp), 1) & Right(strTemp, Len(strTemp) - 1) Range("A1").Offset(i, 0).Value = strTemp i = i + 1 Loop Keith www.kjtfs.com --- Message posted from http://www.ExcelForum.com/ |
All times are GMT +1. The time now is 02:41 AM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com