+ Reply to Thread
Results 1 to 17 of 17

Break points not working

  1. #1
    Registered User
    Join Date
    06-08-2005
    Location
    Kildare, Ireland
    MS-Off Ver
    Windows/Office 365
    Posts
    41

    Break points not working

    I have a spreadsheet that I have been using for some time.
    Suddenly, in just the Worksheet_change event procedure, break points will not work.
    In the same sheet break points do work for other events.
    I've tried everything.
    Can anyone help?

    DesM

  2. #2
    Valued Forum Contributor Richard Schollar's Avatar
    Join Date
    05-23-2006
    Location
    Hampshire UK
    MS-Off Ver
    Excel 2002
    Posts
    1,264

    Re: Break points not working

    Hi

    So events are definitely still firing (ie events have been disabled with something like Application.EnableEvents = False)? Are other events on this sheet that you are trapping still working, or are all events on this particular sheet failing to function (if so, perhaps there is some corrpution at work)?

    It might be worth just going into the VBE, opening up the Immediate Window (Ctrl+G) and checking on Events with:

    Please Login or Register  to view this content.
    and checking it does return True.

    Richard
    Richard Schollar
    Microsoft MVP - Excel

  3. #3
    Registered User
    Join Date
    06-08-2005
    Location
    Kildare, Ireland
    MS-Off Ver
    Windows/Office 365
    Posts
    41

    Re: Break points not working

    Thanks for reply.
    Yes, the break point works on other events (doubleClick and selectionChange) on the same sheet. And these call macros.
    The event itself is firing because I have put Msgbox in several places and it comes up.
    A funny thing too: the event is meant to call a macro but it is not (and it did a week ago). I made up a new macro (just to show MsgBox) and called it and this works. The macros are on different module sheets.
    I've tried making a copy of the sheet, deleting the code in it's module sheet, and then repasting it in from Notepad. No difference.
    I also tried a Code Cleaner.
    Hope you can help.

    DesM

  4. #4
    Forum Expert romperstomper's Avatar
    Join Date
    08-13-2008
    Location
    East Sussex, UK
    MS-Off Ver
    365, varying versions/builds
    Posts
    21,320

    Re: Break points not working

    Can you post the workbook itself? (You can remove any sensitive data)
    Everyone who confuses correlation and causation ends up dead.

  5. #5
    Registered User
    Join Date
    06-08-2005
    Location
    Kildare, Ireland
    MS-Off Ver
    Windows/Office 365
    Posts
    41

    Re: Break points not working

    Thanks, here is the workbook.
    The Input sheet is the one to focus on.
    When you select a cell in the B column, it offers you a dropdown. When you select, this triggers a change event which should trigger the CopyFormula macro (which copies formulea from the Transactions Range to the active row).
    Regards,
    DesM
    Attached Files Attached Files

  6. #6
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,450

    Re: Break points not working

    Looks like DV and breakpoints do not mix.

    If you change a cell in column S on input sheet then breakpoint will work as expected.
    Cheers
    Andy
    www.andypope.info

  7. #7
    Registered User
    Join Date
    06-08-2005
    Location
    Kildare, Ireland
    MS-Off Ver
    Windows/Office 365
    Posts
    41

    Re: Break points not working

    Andy, thanks for input.
    Forgive my ignorance, but what is "DV"?
    Is there a solution? (maybe when I know what DV is I will be obvious).

    DesM

  8. #8
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,450

    Re: Break points not working

    DataValidation, ie. the dropdown list.

    No work around that I can see,
    The following are also ignored.

    Please Login or Register  to view this content.

  9. #9
    Registered User
    Join Date
    06-08-2005
    Location
    Kildare, Ireland
    MS-Off Ver
    Windows/Office 365
    Posts
    41

    Re: Break points not working

    I'm very puzzled. Please have a look at the attached workbook - it works fine!
    Also, my accounts workbook worked fine up until this week.

    DesM
    Attached Files Attached Files

  10. #10
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,450

    Re: Break points not working

    Something screwy with your workbook. If I type VAT instead of pick it from the list then the breakpoint works.

    I can also copy the sheet to a new workbook and get it to break.

    If I comment out all event code except msgbox in change event and then unhide the opening Accs and Trans rows it starts working.

  11. #11
    Registered User
    Join Date
    06-08-2005
    Location
    Kildare, Ireland
    MS-Off Ver
    Windows/Office 365
    Posts
    41

    Re: Break points not working

    Andy, I've just opened a version I saved two weeks ago and everything works fine.
    Do you think, given my limited VBA capability, that I would be better rebuilding the changes I made since then into this, rather than trying to persevere with finding the problem in the modified version?
    Help appreciated.
    DesM

  12. #12
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,450

    Re: Break points not working

    Yes, assuming you know the changes.

    Do it a small step at a time. Add the event code with calls to empty routines.
    Once that is working start populating the routines constantly checking that all is still working and breaking.

  13. #13
    Registered User
    Join Date
    06-08-2005
    Location
    Kildare, Ireland
    MS-Off Ver
    Windows/Office 365
    Posts
    41

    Re: Break points not working

    Thanks Andy for advice.

    DesM

  14. #14
    Registered User
    Join Date
    07-28-2015
    Location
    Minnesota, US
    MS-Off Ver
    2013
    Posts
    2

    Re: Break points not working

    I know this is an old thread, but in case somebody else finds it here's the solution I discovered (almost certainly not the same problem as in the OP).

    I had the problem with breakpoints not stopping the code. I was additionally confused because even if I edited the code, the macro would execute as if the code had not been edited. This was easy to see because I was deleting columns in the table and could not get it to change which columns were deleted.

    The problem was that the changes I made (including adding breakpoints) were not recognized while I had the Find/Replace popup open. As soon as I closed that little window everything worked as expected. Strange bug.

  15. #15
    Registered User
    Join Date
    07-29-2014
    Location
    CA, USA
    MS-Off Ver
    2010
    Posts
    12

    Re: Break points not working

    Quote Originally Posted by dphb View Post
    I know this is an old thread, but in case somebody else finds it here's the solution I discovered (almost certainly not the same problem as in the OP).

    I had the problem with breakpoints not stopping the code. I was additionally confused because even if I edited the code, the macro would execute as if the code had not been edited. This was easy to see because I was deleting columns in the table and could not get it to change which columns were deleted.

    The problem was that the changes I made (including adding breakpoints) were not recognized while I had the Find/Replace popup open. As soon as I closed that little window everything worked as expected. Strange bug.
    Did you ever come up with the fix? I am having the same problem. Changes to the code are not being recognized. Breakpoints are not working. I have restarted computer but did not fix. Hopefully you can shed some light.

  16. #16
    Registered User
    Join Date
    07-29-2014
    Location
    CA, USA
    MS-Off Ver
    2010
    Posts
    12

    Re: Break points not working

    Quote Originally Posted by biocentrism View Post
    Did you ever come up with the fix? I am having the same problem. Changes to the code are not being recognized. Breakpoints are not working. I have restarted computer but did not fix. Hopefully you can shed some light.
    actually i just fixed it. seems the module is corrupted.

    SOLUTION: create a new blank module. copy paste the code from the old module to this new blank module. delete the old module!

  17. #17
    Registered User
    Join Date
    07-28-2015
    Location
    Minnesota, US
    MS-Off Ver
    2013
    Posts
    2

    Re: Break points not working

    Quote Originally Posted by biocentrism View Post
    Did you ever come up with the fix? I am having the same problem. Changes to the code are not being recognized. Breakpoints are not working. I have restarted computer but did not fix. Hopefully you can shed some light.
    My problem was that Excel's Find/Replace window was open. I'm afraid I don't have more insight than that.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

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