I need a macro to delete the first month column and add a blank column at the end.
I need a macro to delete the first month column and add a blank column at the end.
Something like this should get you started:
Please Login or Register to view this content.
_________________
Microsoft MVP 2010 - Excel
Visit: Jerry Beaucaire's Excel Files & Macros
If you've been given good help, use the icon below to give reputation feedback, it is appreciated.
Always put your code between code tags. [CODE] your code here [/CODE]
?None of us is as good as all of us? - Ray Kroc
?Actually, I *am* a rocket scientist.? - JB (little ones count!)
Thanks for the help, Jerry. I believe the code will work with a little tweaking; however, I am getting a runtime error 1004 "Can't change part of merged cell". I think this is because in the actual worksheets the number of rows that need to update vary. I also unmerged the cells in the blank rows in between the used rows. The debugger caught the first instance, after unmerging it caught the merged header row.
Sounds good. If that takes care of this question, please select Thread Tools from the menu above and mark the thread as solved. Thanks.
Sorry for the confusion, the issue is not solved. Since the number of rows vary, the code hangs up when it comes to the merged cell row(new block title). Is there a way around it?
I don't really use merged cells, so don't have a lot of patience for them. My apologies.
Perhaps you can create a macro to unmerge, run the code I gave, then merge the remaining rows again. Just an idea.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks