Consulting

Results 1 to 18 of 18

Thread: Solved: Persistent VBE Window

  1. #1
    Moderator VBAX Master geekgirlau's Avatar
    Joined
    Aug 2004
    Location
    Melbourne, Australia
    Posts
    1,464
    Location

    Solved: Persistent VBE Window

    I have a small but irritating problem ...

    I have a timesheet workbook that I use to record dates, times and projects. This is open all day, and I note the time as I start working on a new task or project.

    A couple of sheets in the workbook have a Worksheet_Change macro (I can't be bothered typing times properly, so whipped up a macro quickly when I was bored!).

    The problem is that periodically the VBE window opens by itself. The workbook is open all day, but I have no need to go into the VBE window. However several times a day I look on my Task Bar and there it is! I shut it down, but as soon as my back is turned (figuratively of course, I haven't worked out how to type that way yet) it pops up again.

    Maybe I should be asking Babydum about poltergeist activity in Excel, but in the meantime does anyone else have a solution?

  2. #2
    Hi geekgirlau,

    As you are doing other work, are you inaverdently hitting some kind of keyboard shortcut, causing the VBE to open?

    Dave
    Quote Originally Posted by geekgirlau
    I have a small but irritating problem ...

    I have a timesheet workbook that I use to record dates, times and projects. This is open all day, and I note the time as I start working on a new task or project.

    A couple of sheets in the workbook have a Worksheet_Change macro (I can't be bothered typing times properly, so whipped up a macro quickly when I was bored!).

    The problem is that periodically the VBE window opens by itself. The workbook is open all day, but I have no need to go into the VBE window. However several times a day I look on my Task Bar and there it is! I shut it down, but as soon as my back is turned (figuratively of course, I haven't worked out how to type that way yet) it pops up again.

    Maybe I should be asking Babydum about poltergeist activity in Excel, but in the meantime does anyone else have a solution?
    Dave
    "The game is afoot Watson"

  3. #3
    Moderator VBAX Master geekgirlau's Avatar
    Joined
    Aug 2004
    Location
    Melbourne, Australia
    Posts
    1,464
    Location
    Well my initial response to this is an indignant "Of course not!".

    But actually ... hmmm, don't know. I'm switching between multiple applications constantly. It appears to happen while Excel does not have the focus. Also I find it hard to believe that I could hit [Alt-F11] without realising it - is there another shortcut for the VBE?

  4. #4
    VBAX Regular
    Joined
    Feb 2006
    Posts
    28
    Location
    There isn't something in the code that is making it pop? does it always open on the same module/procdure?

  5. #5
    Administrator
    Chat VP
    VBAX Guru johnske's Avatar
    Joined
    Jul 2004
    Location
    Townsville, Australia
    Posts
    2,872
    Location
    Have you got an Application.Goto "Something" somewhere where "Something" is also the name of a procedure? (that'll do it)
    You know you're really in trouble when the light at the end of the tunnel turns out to be the headlight of a train hurtling towards you

    The major part of getting the right answer lies in asking the right question...


    Made your code more readable, use VBA tags (this automatically inserts [vba] at the start of your code, and [/vba ] at the end of your code) | Help those helping you by marking your thread solved when it is.

  6. #6
    Moderator VBAX Master geekgirlau's Avatar
    Joined
    Aug 2004
    Location
    Melbourne, Australia
    Posts
    1,464
    Location
    No Application.GoTo ...

    I've now completely cleared Personal.xls (there was only rubbish in there anyway), leaving only the sheet macro below - will let you know if this has resolved anything ...

    [VBA]
    Sub NewWeek()
    If vbYes = MsgBox("Start new week?", vbYesNo + vbQuestion, "New Week?") Then
    On Error Resume Next
    Range("dtmWE") = Range("dtmWE").Value + 7

    Range("Timesheet").ClearContents
    Range("Reimburse").ClearContents
    Range("Comment1").Formula = ""
    Range("Comment2").Formula = ""
    End If
    End Sub

    [/VBA]

  7. #7
    Moderator VBAX Master geekgirlau's Avatar
    Joined
    Aug 2004
    Location
    Melbourne, Australia
    Posts
    1,464
    Location
    Still occurring ...

  8. #8
    Quote Originally Posted by geekgirlau
    Still occurring ...
    Hi geekgirlau,
    Do you have an "Add In" that would be causing it?

    I just saw an Add In somewere else that opens the VBE window.
    Dave
    "The game is afoot Watson"

  9. #9
    Moderator VBAX Master geekgirlau's Avatar
    Joined
    Aug 2004
    Location
    Melbourne, Australia
    Posts
    1,464
    Location
    I just removed the Analysis Toolpak add-in - will let you know if this resolves the issue.

  10. #10
    VBAX Expert Shazam's Avatar
    Joined
    Sep 2005
    Posts
    530
    Location
    You could try this.


    In Excel 2002 and 2003 it has a Detect and Repair feature. Go to the menue bar that says Help Then click on Detect and Repair and go from there. See if that helps.

  11. #11
    Moderator VBAX Master geekgirlau's Avatar
    Joined
    Aug 2004
    Location
    Melbourne, Australia
    Posts
    1,464
    Location
    The problem has not occurred since removing the Analysis Toolpak - will monitor for a couple of days to see what happens.

  12. #12
    Quote Originally Posted by geekgirlau
    The problem has not occurred since removing the Analysis Toolpak - will monitor for a couple of days to see what happens.
    Kool, (got my fingers crossed)
    Dave
    "The game is afoot Watson"

  13. #13
    Moderator VBAX Master geekgirlau's Avatar
    Joined
    Aug 2004
    Location
    Melbourne, Australia
    Posts
    1,464
    Location
    Yep, that seems to have fixed it, although of course if you need the Toolpak it's a bit of an issue ...

  14. #14
    Administrator
    Chat VP VBAX Guru johnske's Avatar
    Joined
    Jul 2004
    Location
    Townsville, Australia
    Posts
    2,872
    Location
    So THAT's where the poltergeist lives!! Good to see you got it sorted
    You know you're really in trouble when the light at the end of the tunnel turns out to be the headlight of a train hurtling towards you

    The major part of getting the right answer lies in asking the right question...


    Made your code more readable, use VBA tags (this automatically inserts [vba] at the start of your code, and [/vba ] at the end of your code) | Help those helping you by marking your thread solved when it is.

  15. #15
    Quote Originally Posted by geekgirlau
    Yep, that seems to have fixed it, although of course if you need the Toolpak it's a bit of an issue ...
    Kool, So there has to be some code or key combination, that when used in conjunction with the Toolpak opens the VBE. Interesting.

    Now that you know its the Toolpak, when you have it loaded, you can watch for the VBE to open, and kinda watch to see what is going on when it happened.
    Dave
    "The game is afoot Watson"

  16. #16
    Moderator VBAX Master geekgirlau's Avatar
    Joined
    Aug 2004
    Location
    Melbourne, Australia
    Posts
    1,464
    Location
    The interesting thing here is that it occurs when Excel does not have the focus - hard to believe that a key combination from outside the application could be launching the VBE window!

  17. #17
    VBAX Expert Shazam's Avatar
    Joined
    Sep 2005
    Posts
    530
    Location
    Quote Originally Posted by geekgirlau
    The interesting thing here is that it occurs when Excel does not have the focus - hard to believe that a key combination from outside the application could be launching the VBE window!

    Hi geekgirlau,


    Have tried to Detect and Repair on your excel? It will put your excel on the default settings.

  18. #18
    Quote Originally Posted by geekgirlau
    The interesting thing here is that it occurs when Excel does not have the focus - hard to believe that a key combination from outside the application could be launching the VBE window!
    Hi geekgirlau,
    What you are saying sounds logical to me.
    Dave
    "The game is afoot Watson"

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •