+ Reply to Thread
Results 1 to 4 of 4

Copy formulas from the Source worksheet to the Target worksheet using a macro

  1. #1
    Registered User
    Join Date
    12-08-2013
    Location
    United States
    MS-Off Ver
    Microsoft 365
    Posts
    57

    Copy formulas from the Source worksheet to the Target worksheet using a macro

    I am trying to copy formulas from the Source worksheet ("Date Range") to the Target worksheet ("Staffing"). The formulas in the Source worksheet are in columns (V5 through AO5). I want to copy the formulas to the Target worksheet to rows A1 through A20. Below is how the data should look in the Target worksheet. I would like to have a macro that copies the formulas automatically to a specific range in the Target worksheet.


    Target Worksheet Data:
    A1: "='Date Range'!$V$5"
    A2: "='Date Range'!$W$5
    A3: "='Date Range'!$X$5
    A4: "='Date Range'!$Y$5
    A5: "='Date Range'!$Z$5
    ..
    ..

    Any guidance on how to write the macro would be appreciated. Thanks!

    - Ron -

  2. #2
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 Version 2405 Win 11 Home 64 Bit
    Posts
    23,885

    Re: Copy formulas from the Source worksheet to the Target worksheet using a macro

    Try this:

    Please Login or Register  to view this content.
    Alan עַם יִשְׂרָאֵל חַי


    Change an Ugly Report with Power Query
    Database Normalization
    Complete Guide to Power Query
    Man's Mind Stretched to New Dimensions Never Returns to Its Original Form

  3. #3
    Forum Expert Vikas_Gautam's Avatar
    Join Date
    06-04-2013
    Location
    Ludhiana,Punjab, India
    MS-Off Ver
    Excel 2013
    Posts
    1,850

    Re: Copy formulas from the Source worksheet to the Target worksheet using a macro

    Sorry Alan
    But a little correction.

    Option Explicit

    Please Login or Register  to view this content.
    Regards,
    Vikas Gautam
    Excel-buzz.blogspot.com

    Excel is not a matter of Experience, its a matter of Application.

    Say Thanks, Click * Add Reputation

  4. #4
    Registered User
    Join Date
    12-08-2013
    Location
    United States
    MS-Off Ver
    Microsoft 365
    Posts
    57

    Re: Copy formulas from the Source worksheet to the Target worksheet using a macro

    Thank you Alansidman and Vikas_Gautam, the code worked great. I appreciate you time and help on helping me with this problem.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Macro to copy data from source workbook to target, based on current month of the year
    By D.Lovell in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 04-27-2014, 05:41 PM
  2. Replies: 0
    Last Post: 02-11-2014, 02:14 PM
  3. Macro To copy data of each month from source to target
    By jonhdoe1 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 09-24-2013, 08:02 AM
  4. Replies: 3
    Last Post: 09-08-2013, 06:38 PM
  5. button to copy worksheet with formulas referencing previous worksheet
    By Alexelius in forum Excel - New Users/Basics
    Replies: 1
    Last Post: 07-28-2011, 09:40 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1