Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Microsoft Office > Excel VBA > Excel VBA
|
Excel VBA Discuss using VBA for Excel programming.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Excel VBA section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old February 28th, 2013, 05:28 PM
Registered User
 
Join Date: Feb 2013
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default How to do an automation for copy paste, added new row (macro)

Hello
I have attached file
http://www.sendspace.com/file/wjh0oe

I want to automated a some step (tab table Z)
Thus, for example, that in X 2012:

1) I want to copy D16:E16
2) added a new one blank below before the paste D17:E17
3) converted the 2011 to 2012 in cells D17: E17 (ctr+h function find 2011 replace the 2012)
and by analogy, 1) 2) 3) for Y

And just every year


In the point 3) conversion step, it can converts the 2011 to 2012 or 2010 to 2012 as comfortably.

Regards. Thank you in advance for your answer
 
Old March 3rd, 2013, 10:00 PM
Friend of Wrox
 
Join Date: Sep 2005
Posts: 812
Thanks: 1
Thanked 53 Times in 49 Posts
Default

Hi

You can use the Range.Copy method to achieve that

http://msdn.microsoft.com/en-us/libr...ice.14%29.aspx

http://msdn.microsoft.com/en-us/libr.../ff837760.aspx

Please refer the above and start your program. Happy coding!

Cheers
Shasur
__________________
C# Code Snippets (http://www.dotnetdud.blogspot.com)

VBA Tips & Tricks (http://www.vbadud.blogspot.com)





Similar Threads
Thread Thread Starter Forum Replies Last Post
Copy header row only once in VBA macro jules1029 Excel VBA 1 December 9th, 2012 09:32 AM
help in how to copy macro in new added sheet zmhnk Excel VBA 1 April 9th, 2012 10:22 PM
Please help: Run Time Error -40036 While running the macro for copy and paste vamsidhar BOOK: Excel 2007 VBA Programmer's Reference ISBN: 978-0-470-04643-2 2 June 22nd, 2010 08:08 AM
Copy and Paste the value waka Excel VBA 7 October 28th, 2009 10:08 PM
Copy, Paste dpkbahuguna Beginning VB 6 1 October 26th, 2006 10:30 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.