Rubberboots Rubberbootsian
|
Posted: Mon Aug 07, 2006 10:11 pm Post subject: |
|
|
| LeaWildcat : | | Quote: | varTemp2 = Mid(varTemp, 5) 'retrieve the rows from the above address
|
can you save a step by saying varTemp2 = Mid(varTemp, 5) + 5? |
Not really. I need to do something at cell Range(AD & Whatever the current row is). I only need to add the 5 rows after it's pasted to the current row.
| Quote: | Also this seems redundant, like you are assigning it twice.
| Quote: | varTemp2 = Mid(varTemp, 5) 'retrieve the rows from the above address
varTarget = "ad" & varTemp2 'assign the target address to a variable for c & p
and
Range(varTemp).Activate 'um...I'm not sure why I take this side-trip.
varTemp2 = varTemp2 + 5 'add 5 rows to the place where I pasted the custom formulas
varTemp3 = "aa" & varTemp2 'store the cell in column AA 5 rows down from the paste
Range(varTemp3).Activate 'move to the above set cell
|
|
I'm only changing the value of varTemp2 after I've done the pasting and am ready to move on where I may call the procedure again.
It may seem redundant but trust me it's not. The only thing I can't figure out why I did something there is activating Range(varTemp). I'm sure it was important to something at some point but it's definitely doing nothing now.
There is an issue with a superfluous variable that is resolved if I did need to return to Range(varTemp) at some point. Again, I can't see what that was and I wrote this so long ago I can't remember what it was now.
I do appreciate your help though.  |
|