+ Reply to Thread
Results 1 to 3 of 3

Excel Visual Basic Macro code stops working

  1. #1
    Registered User
    Join Date
    10-04-2013
    Location
    ddd
    MS-Off Ver
    Excel 2010
    Posts
    2

    Excel Visual Basic Macro code stops working

    For my job I've been working on a large excel - based reporting system, being used by a lot of people in the company. There are a lot of macro's behind it and recently I encountered a problem I don't seem to be able to solve myself. I am hoping someone on this site could help me with it.

    The problem is the following:

    The reporting system consists of an excelfile with several sheets. There is visual basic code behind the sheets, as well as code in 9 modules. The code and the sheets have been tested and works. Sometimes, however, some of the macros behind the worksheets stop working (without an error coming up). For example: I've programmed that the excelfile cannot be closed by clicking on the x, but this suddenly is possible. Also: I coded that on doubleclicking a range of cells, the cells receive a specific color, but in this case just a cursor appears. My question is the following:

    Does anybody of you already dealt with a similar problem? What could the reason for this problem be? Is there a fault somewhere in my code and how could I find it? When one of my colleague encountered the problem I went to have a look and opened the VB - editor, but no fault was marked or seen. The only solution to the problem was to close ALL excel - sheets on this computer (often they use several instances of my program at once: they all stop working at once also) and start them back up: then everything works properly again.

    I've tried re-evaluating the code, used a code cleaner, ... and I'm getting out of ideas: is there anyone with an idea how to solve this?

    Thanks in advance

  2. #2
    Forum Expert
    Join Date
    04-22-2013
    Location
    .
    MS-Off Ver
    .
    Posts
    4,418

    Re: Excel Visual Basic Macro code stops working

    Sounds like application.enableevents is being set to false.

  3. #3
    Registered User
    Join Date
    10-04-2013
    Location
    ddd
    MS-Off Ver
    Excel 2010
    Posts
    2

    Re: Excel Visual Basic Macro code stops working

    Quote Originally Posted by yudlugar View Post
    Sounds like application.enableevents is being set to false.

    Yep, that's correct! Just found out that another excelsheet is running on those computers and enableevents is put to false there. Thanks for the respons!

+ 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. The Code Window in the Visual Basic Editor of Excel
    By Marilyaryott in forum Tips and Tutorials
    Replies: 0
    Last Post: 03-23-2012, 10:31 PM
  2. Excel 2007 : Excel Combo-box Visual Basic Code
    By daibao in forum Excel General
    Replies: 3
    Last Post: 08-18-2010, 02:35 AM
  3. Visual basic print code for excel 2007
    By mattless1 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-09-2009, 07:14 PM
  4. [SOLVED] Can I run Visual Basic procedure using Excel Visual Basic editor?
    By john.jacobs71 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 12-26-2005, 10:25 AM
  5. [SOLVED] How do I hide my Visual basic code in Excel?
    By geoffc in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 04-07-2005, 08:07 AM

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