ouestque
asked on
Excel VBA: New range if copied to new location.
What VBA code would I use to determine the new range if a user copied/pasted the range to a new location. (See Examples)
Example1:
Starting Range: C20:F30
User Moves Range to: H4
Solution: In this case, if the user cut C20:F30 and pasted it into cell H4 the new range would be: H4:K14.
Example2:
Starting Range: AB42:AD60
User Moves Range to:DD50
Solution in this case, if the user cut AB42:AD60 and pasted it to cell DD50 the new range would be: DD50:DF68
Example3:
Starting Range: AB42:AD60
User Moves Range to:A7
Solution in this case, if the user cut AB42:AD60 and pasted it to cell A7 the new range would be: A7:C25
Example1:
Starting Range: C20:F30
User Moves Range to: H4
Solution: In this case, if the user cut C20:F30 and pasted it into cell H4 the new range would be: H4:K14.
Example2:
Starting Range: AB42:AD60
User Moves Range to:DD50
Solution in this case, if the user cut AB42:AD60 and pasted it to cell DD50 the new range would be: DD50:DF68
Example3:
Starting Range: AB42:AD60
User Moves Range to:A7
Solution in this case, if the user cut AB42:AD60 and pasted it to cell A7 the new range would be: A7:C25
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER