+ Reply to Thread
Results 1 to 2 of 2

Cell reference error in macro?

  1. #1
    Registered User
    Join Date
    davis, ca
    MS-Off Ver
    office 365

    Cell reference error in macro?

    I am trying to record a simple macro to make a line chart showing date (x-axis) and data value (y-axis). I want to use the same macro in many worksheets. The work sheet formats are identical. I assume I should be specifying relative cell references in the macro because I want to use the macro in different worksheets from the worksheet in which it was created. However, when I run the macro in a worksheet different from the worksheet in which it was recorded I get an error that I cannot decipher:

    'Run time error 1004
    Application defined or object defined error'

    The help screen is Greek to me. I don't know VB. Any ideas?
    Attached Files Attached Files

  2. #2
    Forum Moderator 6StringJazzer's Avatar
    Join Date
    Tysons Corner, VA, USA
    MS-Off Ver
    Pro 2019

    Re: Cell reference error in macro?

    To diagnose a code error we have to see the code. The file you attached is not macro-enabled so has no code. You must save a file with macros as a .xlsm file.
    Making the world a better place one fret at a time | | |會 |會 |會 |會 | |:| | |會 |會
    Please read the rules
    If someone helped you, click on the star icon at the bottom of their post
    If your problem is solved, go to Thread Tools and select Mark This Thread Solved
    Don't attach a screenshot--just attach your Excel file! It's easier and will let us experiment with your data, formulas, and code.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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


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