Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have written a macro to initialize a worksheet that is copied. There are
three elements that need to be changed throughout the worksheet for the upcoming year: 1) Change caption on commandbuttons to show 2009 2) Change the date for each of the 12 budgets to correct year 3) change the 2008 to 2009 in the formulas in some of the cells. Elements 1 and 2 are working, but I cannot figure out how to look in a formula in a cell for the value 2008 and change it to 2009. This is what I had, but it did not work: Range("S5:X705).Select For Each cell In Selection cell.Value = Replace(cell.Value, "2008", "2009") Next cell I copied this from a website I found on replacing a value. Thanks for your help, Les |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Find and Replace in a Macro | Excel Programming | |||
Find & Replace and Find & Insert macro help needed | Excel Programming | |||
Macro to Find & Replace | Excel Worksheet Functions | |||
Using Find and Replace to replace " in a macro | Excel Programming | |||
A Macro to Do Find and Replace | Excel Programming |