Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Woohoo, thanks for all the help, had to sleep for a while, Toppers
macro works fine, I cant express my appreciation, this really saved me. Darrell Ken Johnson wrote: Hi, If it has to be a macro this works if you run it after selecting the range of cells... Public Sub add_zeros() Dim vaData As Variant vaData = Selection Dim I As Long Dim J As Long For I = 1 To UBound(vaData, 1) For J = 1 To UBound(vaData, 2) vaData(I, J) = "'" & _ WorksheetFunction.Rept("0", 9 - Len(vaData(I, J))) _ & vaData(I, J) Next J Next I Selection = vaData End Sub Ken Johnson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
how do I email amacro? | Excel Worksheet Functions | |||
link to combobox | Excel Discussion (Misc queries) | |||
In a Macro replacing $x with ($x + i) gives x+1 not $x+1 as expe. | New Users to Excel | |||
Search, Copy, Paste Macro in Excel | Excel Worksheet Functions | |||
Editing a simple macro | Excel Worksheet Functions |