![]() |
Routine procedures/formatting same as previous cell
Hi,
I have a 40 tabs spreadsheet. On a weekly basis I need to update half of the sheets and the rest at the end of the month. Each week I need to add the end of week data, so basically modify the formatting of the new cells to match the formatting of the previous cells, extend the border lines to include the new set of cells in the new column and if there is any formulas in the previous cell, copy it to the new cell. This only applies to the rows that has cells filled, for the empty rows nothing should happen. Can I write a macro that I can use on sheets i need to update to do what i have described above? Thanks!! |
Routine procedures/formatting same as previous cell
The bes way of accomplishing this is with the code below
for each ws in worksheets if worksheet.name = "teststring" then Enter your code here end if next ws or If you name use a unique naming convention for the worksheets that have to be entered each week verses the ones at the end of the month then you can use the instr function to make the changes only to certain worksheets. for each ws in worksheets if instr(worksheet.name,"teststring") 0 then Enter your code here end if next ws "Jean" wrote: Hi, I have a 40 tabs spreadsheet. On a weekly basis I need to update half of the sheets and the rest at the end of the month. Each week I need to add the end of week data, so basically modify the formatting of the new cells to match the formatting of the previous cells, extend the border lines to include the new set of cells in the new column and if there is any formulas in the previous cell, copy it to the new cell. This only applies to the rows that has cells filled, for the empty rows nothing should happen. Can I write a macro that I can use on sheets i need to update to do what i have described above? Thanks!! |
All times are GMT +1. The time now is 11:18 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com