Results 1 to 8 of 8
  1. #1
    GraeagleBill's Avatar
    GraeagleBill is offline Experienced Old Geezer
    Windows 7 64bit Access 2003
    Join Date
    Feb 2011
    Posts
    2,097

    Need some method like "Debug.BreakHere"

    Is there a method whereby I can set a breakpoint from code? I have a bug in some application initialization code and I need to break before the bug so I can find it.

    Thanks,
    Bill

  2. #2
    rzw0wr is offline I will always be a newbie
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2013
    Location
    Indiana
    Posts
    479
    Left click in the gray area to the left of the line of code.
    A red dot will appear. The code will stop there.
    F8 will single step and F5 will continue.
    Debug/Clear Break Points clears them.

    Dale

    TIP:
    ctl-G opens the immediate window. Typing Debug.Print YourVariable will show int in this window.

    Dale

  3. #3
    GraeagleBill's Avatar
    GraeagleBill is offline Experienced Old Geezer
    Windows 7 64bit Access 2003
    Join Date
    Feb 2011
    Posts
    2,097
    I could get what I want if I could just open the database view. I used to be able to do that by holding down the shift key and double-clicking the mdb file. Can that still be done with some other action?

  4. #4
    GraeagleBill's Avatar
    GraeagleBill is offline Experienced Old Geezer
    Windows 7 64bit Access 2003
    Join Date
    Feb 2011
    Posts
    2,097
    Dale,
    Not being clear enough. I need to set a breakpoint from code. That is, a vba statement that will set a breakpoint to itself.

  5. #5
    GraeagleBill's Avatar
    GraeagleBill is offline Experienced Old Geezer
    Windows 7 64bit Access 2003
    Join Date
    Feb 2011
    Posts
    2,097
    Maybe there's a way to set a breakpoint such that it will remain when the app is closed and then reopened? That's really the problem I'm having.

  6. #6
    rzw0wr is offline I will always be a newbie
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2013
    Location
    Indiana
    Posts
    479
    try Stop.

    Dale

  7. #7
    GraeagleBill's Avatar
    GraeagleBill is offline Experienced Old Geezer
    Windows 7 64bit Access 2003
    Join Date
    Feb 2011
    Posts
    2,097
    That's all I needed. I can now stop and set whatever breakpoints are needed.
    Thanks,
    Bill

  8. #8
    rzw0wr is offline I will always be a newbie
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2013
    Location
    Indiana
    Posts
    479
    My pleasure.

    Dale

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Use "FindNext" Method in KML Text File
    By JonMulder in forum Programming
    Replies: 0
    Last Post: 02-08-2013, 12:59 PM
  2. Replies: 4
    Last Post: 01-03-2013, 03:50 PM
  3. Replies: 11
    Last Post: 03-29-2012, 02:32 PM
  4. Replies: 16
    Last Post: 07-22-2011, 09:23 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums