Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I am trying have a macro edit a series of cells automatically. Each cell is
the same format but has different information. Basically I am trying to take a cell with a format of 0100 AM and have this changed to 01:00 AM. There is a large range of these cells thus the reason for wanting to automate the insert of the colon. -- Laddie |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
If the values are genuine times, you can just change the format. If not,
select the cells and run this small macro: Sub colonize() For Each r In Selection v = r.Text r.Clear r.NumberFormat = "@" r.Value = Left(v, 2) & ":" & Right(v, 5) Next End Sub -- Gary''s Student - gsnu200820 "Laddie" wrote: I am trying have a macro edit a series of cells automatically. Each cell is the same format but has different information. Basically I am trying to take a cell with a format of 0100 AM and have this changed to 01:00 AM. There is a large range of these cells thus the reason for wanting to automate the insert of the colon. -- Laddie |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Gary -
Thank you very much, it works like a charm...perfectly. I am far from a programmer but have always been able to fight my way through Excel issues in the past but this was one which was driving me crazy. Can't thank you enough.... I owe you a beer. -- Laddie "Laddie" wrote: I am trying have a macro edit a series of cells automatically. Each cell is the same format but has different information. Basically I am trying to take a cell with a format of 0100 AM and have this changed to 01:00 AM. There is a large range of these cells thus the reason for wanting to automate the insert of the colon. -- Laddie |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
editing chart series data w/ "keyboard only" (2007) | Charts and Charting in Excel | |||
editing multiple cells with a macro | Excel Discussion (Misc queries) | |||
editing liked cells | Excel Discussion (Misc queries) | |||
Need Help Editing Cells | New Users to Excel | |||
editing cells... | Excel Programming |