Forum Discussion

donfaison-CAHA's avatar
donfaison-CAHA
Copper Contributor
Jan 26, 2024

Multiple *.xlsm files no longer recognize attached VBA modules and files are uneditable/unsaveable.

This began with Excel 365 version 2307 some months ago, and got considerably worse with version 2312.  It used to be two or three times a week, but now it is happening three or four times daily.  Before, I just lost the VBA modules (which I learned to export, then I could save the file as *.xlsx and import the modules, resave as *.xlsm and keep on working.  Now Excel is crashing daily and leaving me unable to save Excel *.xlsm files in ANY format!  After the crash I reopen the file and the modules exist but I can neither see into them nor export them, and I cannot save the file nor repair it (rather, Excel repair always fails).  This happens with files I have used for years and for files I just created today. 

The only suggestion I found on-line was to rename the file as *.zip and re-rename as *.xlsm, which did not work.  I've started making daily backups but I lose a lot of data each day, and sometimes the previous day's backup crashes, too! ANY help would be appreciated.  

6 Replies

  • peiyezhu's avatar
    peiyezhu
    Bronze Contributor

    After the crash I reopen the file and the modules exist but I can neither see into them nor export them, and I cannot save the file nor repair it (rather, Excel repair always fails).

    I guess the defender may result it.
    If you want to avoid it occurs again,I guess you need close the defender anti-virus when.you open .xlsm file next time.


    As to the VBA module,if you have backup, just restore it.

    If you want to extract the Vba codes from the file you can not see,you can upload your .xlsm file,let us see whether it is possible to export those VBA modules as text.

    • donfaison-CAHA's avatar
      donfaison-CAHA
      Copper Contributor

      peiyezhu I am already exporting the modules as *.bas and have already doubly backed up some as text.  The problem is that the *.xlsm file is now useless (un-repairable).  I am losing one to three files DAILY and have to TRY to re-enter all of the data I lost since the last save.  Some of the larger files I am backing up to *.xlsx then importing the *.bas and resaving as *.xlsm (but even that does not work all of the time as the "new" *.xlsm opens as un-editable/un-repairable.

      • donfaison-CAHA's avatar
        donfaison-CAHA
        Copper Contributor
        P.S.S. ESET anti-virus installed by the company, cannot be turned off.

Resources