• Delete Invisible Macro

    Author
    Topic
    #353790

    Spreadsheet created in E95, moved to E97, then to E2000. I’ve deleted the macro, but still get the “Enable/Disable” question upon opening the file. I’ve checked all logical places (this workbook, all open workbooks, etc.) and I don’t THINK there are any macros there. Any thoughts?
    thanks

    Viewing 1 reply thread
    Author
    Replies
    • #518327

      Did you remove the modules – not just deleted the macros in that modules – that originally contained the macros?

      • #518341

        I have now! I deleted all named ranges – nothing changed. I had a module1 and it is now gone and along with it the annoying message. So it was tied to the empty module! If I ask why? is there a simple answer?

        And thanks so much

        • #518360

          I’ve seen this before.

          I suspect Excel only checks for the presence of modules/forms when determining if macros exist. It doesn’t go the extra step to determine if any code exists in the modules.

          • #518361

            That’s the case indeed! You need to remove the modules even if they’re empty.
            I’ve never heard or experienced that named ranges could give rise to the enable/disable macro message.

            • #518380

              Of course I can’t find the documentation now! .
              I found that old spreadsheets with named ranges (I think protection might have been involved as well) would often give false warnings. I even got a confirmation from MS.
              I don’t remember if it was 95 to 97 or 2000.
              Believe me it happened!!

            • #518423

              Was it the macro warning or the “Do you want to update links” question. Excel can ask that question if there are defined names that contain links, but I have never heard of it causing the macro warning.

            • #518449

              It was the macro warning. It related to a workbook that was created in Excel 95. When I opened it in (97/2000 ?) I got a warning. I sent it to MS and got a reply that the range names were causing the problem.
              (I hate to mention it, but I did post it in the old forum )
              I can’t find the correspondence. I have a test file from that period, but now I can’t duplicate the problem.
              I think I’ll drop this until I can find some more info.

            • #518460

              This can happen it the ‘Names’ were referring to old EXCEL4 functions like GET.DOCUMENT for example.

            • #518513

              I found it :
              (Nothing is too obscure)
              Q171661 and Q199972
              A false macro warning can occur with Excel 97 when:

              The workbook contains a defined name that uses syntax to refer to nonadjacent cell ranges; however the defined name actually refers to adjacent cell ranges.
              -and-
              The last three rows in the defined name are rows greater than or equal to row 600 and increase in value from left to right.
              For example, if you create a worksheet named “Plan,” a defined name that refers to the following ranges causes the problem:
              =Plan!$A$1:$A$1,Plan!$A$1:$A$1,Plan!$A$1:$A$1,Plan!$A$1:$A$1,
              Plan!$A$1:$A$1,Plan!$A$1:$A$1,Plan!$A$1:$A$1,Plan!$A$1:$A$600,
              Plan!$A$601:$A$602
              NOTE: Other similarly defined names may also cause this behavior.
              -or-
              The ThisWorkbook module is missing from the workbook in the Project Explorer window in Microsoft Visual Basic Editor.
              This problem was corrected in Microsoft Excel 97 SR-1.
              -or-
              This problem may occur when the following conditions are true:
              A defined name has been inserted into the workbook.
              -and-
              The defined name refers to a constant of 1.5.

            • #518615

              Well done. All I can say is:
              You gotta love the M$ office products…

    • #518335

      Besides Modules that might still be attached, this message may appear if you have named ranges as well

    Viewing 1 reply thread
    Reply To: Delete Invisible Macro

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: