+ Reply to Thread
Results 1 to 10 of 10

Can't open module

  1. #1
    Registered User
    Join Date
    08-08-2023
    Location
    Texas, USA
    MS-Off Ver
    MS Office 365
    Posts
    49

    Can't open module

    Hello,

    I have a set of macros in several workbooks that I have been running everyday for about a year now without issues (except for ones I have been been able to easily fix myself).
    Starting this morning excel started crashing when running one of them.
    I narrowed it down to which workbook had the macro that was causing the crash, but...

    When I open the developer tab, and double click on any of the modules in the workbook, nothing happens (grey screen to right where code usually pops up)

    Snip of VBA menu attached... neither module will open.

    Any/All help appreciated!
    Attached Images Attached Images

  2. #2
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    48,565

    Re: Can't open module

    Not much we can do or diagnose with a picture.


    Fast answers need visual help. Please read the yellow banner at the top of this page on how to attach a file and a mocked up solution.
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


  3. #3
    Registered User
    Join Date
    08-08-2023
    Location
    Texas, USA
    MS-Off Ver
    MS Office 365
    Posts
    49

    Re: Can't open module

    My apologies,

    I was hesitant to include the actual workbook since there is so much potentially sensitive data in it, and the macro specifically calls out the workbook name, so I couldn't change title either without alot of work.

    That being said, I saved the document (with the same name) in a separate location and replaced all data with random values within a reasonable range.

    After saving in the different location, I was able to open up the modules in question, so uploading now wouldn't show the problem of not being able to open the modules.

    The original location is on a company server, so perhaps I need to get with my local IT on settings of the folder...

  4. #4
    Valued Forum Contributor
    Join Date
    09-19-2008
    Location
    It varies ...
    MS-Off Ver
    Office365 - 64bit
    Posts
    862

    Re: Can't open module

    To rule out that it's not a file corruption, save the file to your desktop & close Excel, then open the file and confirm you can see the modules. If so, save back to the LAN location & close Excel, open it up again and check the modules. If you can't see them then yes - likely a security setting IT has changed.
    MatrixMan.
    --------------------------------------
    If this - or any - reply helps you, remember to say thanks by clicking on *Add Reputation.
    If your issue is now resolved, remember to mark as solved - click Thread Tools at top right of thread.

  5. #5
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    48,565

    Re: Can't open module

    OK, back with you then.

  6. #6
    Registered User
    Join Date
    08-08-2023
    Location
    Texas, USA
    MS-Off Ver
    MS Office 365
    Posts
    49

    Re: Can't open module

    Matrixman,

    When I try to 'save as' on the desktop I get the following message:
    Errors were detected while saving 'FILE PATH & NAME'. Microsoft Excel May be able to save the file by removing or repairing some features. To make the repairs in a new file, click Continue. To cancel saving the file, click Cancel.

    when i click continue, the following message:
    Excel encountered errors during save. However Excel was able to minimally save your file to 'FILE PATH & NAME'

    when that dialog box is closed, I get the message from attached snip.


    I assume that means my file has been corrupted?
    Attached Images Attached Images

  7. #7
    Valued Forum Contributor
    Join Date
    09-19-2008
    Location
    It varies ...
    MS-Off Ver
    Office365 - 64bit
    Posts
    862

    Re: Can't open module

    Yup - looks like and would explain the "stopped working suddenly". Create a new workbook and manually copy your data and code (you can export your modules and import them to the new one). Good luck!

  8. #8
    Registered User
    Join Date
    08-08-2023
    Location
    Texas, USA
    MS-Off Ver
    MS Office 365
    Posts
    49

    Re: Can't open module

    Thanks Matrixman, I'll manually move everything to a fresh file (sigh) and see if that fixes it.
    I'll let you know when I'm done.

  9. #9
    Registered User
    Join Date
    08-08-2023
    Location
    Texas, USA
    MS-Off Ver
    MS Office 365
    Posts
    49

    Re: Can't open module

    Well I finished redoing the sheet manually, and replaced the old corrupted file, and everything is working smoothly again.

    Thanks Matrixman!

  10. #10
    Valued Forum Contributor
    Join Date
    09-19-2008
    Location
    It varies ...
    MS-Off Ver
    Office365 - 64bit
    Posts
    862

    Re: Can't open module

    It's a pain and even more annoying when there's no real answer to "why?!?!" but glad you got it back up and running. And thank you for the rep point :-)

+ 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. upload a new Module to overwrite previous module to update expriration date!
    By JJFletcher in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 02-10-2021, 07:41 PM
  2. [SOLVED] Extra Sheet not a Chart or Old Macro Module or Worksheet - Appears to be normal module???
    By Doc.AElstein in forum Excel Programming / VBA / Macros
    Replies: 21
    Last Post: 06-06-2017, 04:10 AM
  3. Compile error in hidden module: Module 1 when workbook opened on different machine!?
    By MathUKTeacher in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 05-06-2015, 04:38 PM
  4. [SOLVED] Link to open vba editor on specific module
    By ScabbyDog in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 09-17-2012, 02:16 PM
  5. [SOLVED] On open, insert text file as module
    By Marco-Kun in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 06-26-2012, 11:12 AM
  6. how to access Sheet module, normal module, Worbook module to type code
    By alibaba in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-31-2009, 07:51 AM
  7. Module to apply to all open worksheets
    By nhojflies in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 07-14-2009, 12:13 PM

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