+ Reply to Thread
Results 1 to 3 of 3

macro refers back to tab where it was recorded instead of using values of current tab

  1. #1
    Registered User
    Join Date
    02-27-2015
    Location
    Australia
    MS-Off Ver
    Excel 2013
    Posts
    18

    macro refers back to tab where it was recorded instead of using values of current tab

    Hello All,
    I have identical tables on two separate tabs, but they get their data from different places via external references. The table in tab A has values of store A and tab B has values of store B.
    When I record a macro on tab A and then I try to run it on tab B, it uses the values from tab A at copy paste functions, i.e. pastes values from tab A (store A`s data) into tab B. I have not had this issue before. Earlier when I ran macros they did not take the references from the tab on which I recorded them. Maybe something has changed in the basic settings of my Excel? Can anyone help me with this problem?
    Thank you.

  2. #2
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258

    Re: macro refers back to tab where it was recorded instead of using values of current tab

    Hello atoga,

    Your description of the problem is too general to provide you with specific answers. You will need to post a workbook with before and after examples.

    Please change or redact any private, confidential, or sensitive information prior to posting.

    How To Post Your Workbook
    1. At the bottom right of the Reply window, Click the button Go Advanced
    2. At the top of the Your Message Window, in the first row of icons, Click the Paperclip icon.
    3. Click the Add Files button at the top right in the dialog box. This displays the File Manager dialog.
    4. Click the Select Files button at the bottom middle of the dialog.
    5. In the new window Find the file you want to upload, select it, and Click Open.
    6. You will now be back in the File Manager dialog. Click the bottom Middle button Upload File.
    7. Wait until the file has completely uploaded before you exit the File Manager dialog.
    Sincerely,
    Leith Ross

    Remember To Do the Following....

    1. Use code tags. Place [CODE] before the first line of code and [/CODE] after the last line of code.
    2. Thank those who have helped you by clicking the Star below the post.
    3. Please mark your post [SOLVED] if it has been answered satisfactorily.


    Old Scottish Proverb...
    Luathaid gu deanamh maille! (Rushing causes delays!)

  3. #3
    Registered User
    Join Date
    02-27-2015
    Location
    Australia
    MS-Off Ver
    Excel 2013
    Posts
    18

    Re: macro refers back to tab where it was recorded instead of using values of current tab

    Hi Leith,
    Thank you for the answer. I have attached a simplified file with a recorded macro. (Please note that the yellow tabs are located in another workbook in my PC, I have just moved them now into the same workbook as the charts to show you the problem. And I have of course hundreds of other tables and charts in my original workbook, but the structure is the same as in this sample.)
    My aim is just to add the Jun14-Jun15 data to the charts. I have recorded the macro on SC Total and tried to run it on SC Fasteners but without success.
    Thank you!
    Atoga
    Attached Files Attached Files

+ 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] Recorded Pivot Table Macro Doesn't Do What I Recorded!
    By diakonos1984 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 03-26-2013, 11:01 AM
  2. [SOLVED] Run recorded macro based on current sheet, not the original sheet
    By magillmjl in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 08-22-2012, 06:23 PM
  3. [SOLVED] How to run a recorded macro when cell values change?
    By Clue_Less in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 06-15-2012, 12:01 PM
  4. [SOLVED] Edit Recorded Macro to filter column with about 200k rows based on a list of values.
    By rocksan in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 04-19-2012, 03:35 AM
  5. recorded macro for chart has no x values
    By Leon V (AW) in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-23-2011, 04:14 AM
  6. Hyperlink refers back to previous sheet?
    By simonwilliams in forum Excel General
    Replies: 8
    Last Post: 12-09-2009, 07:23 AM
  7. Copy (values only) not ALL using a recorded macro
    By Traymond in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 04-22-2009, 06:26 PM
  8. Excel macro, editing recorded cell.. not current
    By TroyT in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 01-12-2006, 09:30 AM

Tags for this Thread

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