Faintkitara
Board Regular
- Joined
- Jun 23, 2016
- Messages
- 59
Hello,
I'm trying to figure out how to make a macro that copies all columns named " Current Projection" in row 4 and pastes them right after each other. So wherever a column says "Current Projection" in row 4 i pretty much want that column to be duplicated. I tried doing this myself but of course macrorecorder can only go so far. For example row 4 would look like this (with corresponding data below it):
[TABLE="width: 500"]
<tbody>[TR]
[TD]5/5[/TD]
[TD]5/12[/TD]
[TD]Current Projection[/TD]
[TD]Accounts[/TD]
[TD]Current Projection[/TD]
[TD]Totals[/TD]
[/TR]
</tbody>[/TABLE]
I want it to look like this:
[TABLE="width: 500"]
<tbody>[TR]
[TD]5/5[/TD]
[TD]5/12[/TD]
[TD]Current Projection [/TD]
[TD]Current Projection[/TD]
[TD]Accounts[/TD]
[TD]Current Projection[/TD]
[TD]Current Projection [/TD]
[TD]Totals[/TD]
[/TR]
</tbody>[/TABLE]
On top of that I also wanted to get code on how to rename every first "Current Projection" column of the duplicates, a date that is seven days more than the date listed the column before it.
So from this:
[TABLE="width: 500"]
<tbody>[TR]
[TD]5/5[/TD]
[TD]5/12[/TD]
[TD]Current Projection[/TD]
[TD]Current Projection[/TD]
[TD]Accounts [/TD]
[TD]7/2[/TD]
[TD]7/9[/TD]
[TD]Current Projection[/TD]
[TD]Current Projection[/TD]
[TD]Totals[/TD]
[/TR]
</tbody>[/TABLE]
To this:
[TABLE="width: 500"]
<tbody>[TR]
[TD]5/5[/TD]
[TD]5/12[/TD]
[TD]5/19[/TD]
[TD]Current Projection[/TD]
[TD]Current Projection[/TD]
[TD]Accounts[/TD]
[TD]7/2[/TD]
[TD]7/9[/TD]
[TD]7/16[/TD]
[TD]Current Projection[/TD]
[/TR]
</tbody>[/TABLE]
Any response would be greatly appreciated! Thank you!!!
I'm trying to figure out how to make a macro that copies all columns named " Current Projection" in row 4 and pastes them right after each other. So wherever a column says "Current Projection" in row 4 i pretty much want that column to be duplicated. I tried doing this myself but of course macrorecorder can only go so far. For example row 4 would look like this (with corresponding data below it):
[TABLE="width: 500"]
<tbody>[TR]
[TD]5/5[/TD]
[TD]5/12[/TD]
[TD]Current Projection[/TD]
[TD]Accounts[/TD]
[TD]Current Projection[/TD]
[TD]Totals[/TD]
[/TR]
</tbody>[/TABLE]
I want it to look like this:
[TABLE="width: 500"]
<tbody>[TR]
[TD]5/5[/TD]
[TD]5/12[/TD]
[TD]Current Projection [/TD]
[TD]Current Projection[/TD]
[TD]Accounts[/TD]
[TD]Current Projection[/TD]
[TD]Current Projection [/TD]
[TD]Totals[/TD]
[/TR]
</tbody>[/TABLE]
On top of that I also wanted to get code on how to rename every first "Current Projection" column of the duplicates, a date that is seven days more than the date listed the column before it.
So from this:
[TABLE="width: 500"]
<tbody>[TR]
[TD]5/5[/TD]
[TD]5/12[/TD]
[TD]Current Projection[/TD]
[TD]Current Projection[/TD]
[TD]Accounts [/TD]
[TD]7/2[/TD]
[TD]7/9[/TD]
[TD]Current Projection[/TD]
[TD]Current Projection[/TD]
[TD]Totals[/TD]
[/TR]
</tbody>[/TABLE]
To this:
[TABLE="width: 500"]
<tbody>[TR]
[TD]5/5[/TD]
[TD]5/12[/TD]
[TD]5/19[/TD]
[TD]Current Projection[/TD]
[TD]Current Projection[/TD]
[TD]Accounts[/TD]
[TD]7/2[/TD]
[TD]7/9[/TD]
[TD]7/16[/TD]
[TD]Current Projection[/TD]
[/TR]
</tbody>[/TABLE]
Any response would be greatly appreciated! Thank you!!!