Results 1 to 12 of 12
  1. #1
    New Lounger
    Join Date
    Jan 2001
    Location
    Maryland, USA
    Posts
    19
    Thanks
    0
    Thanked 0 Times in 0 Posts

    VBeditor bug? (access 2000 sr-1)

    I converted a db from Access 97 to 2000 and now can't seem to get my VBeditor working right. When I set breakpoints and then "run", the "Macro..." window pops up. When I try to "step into", nothing happens. I can't seem to find anything in this forum that relates to this problem. I haven't tried reloading Access 2000 yet. Anyone have any ideas?

  2. #2
    Plutonium Lounger
    Join Date
    Dec 2000
    Location
    Sacramento, California, USA
    Posts
    16,775
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: VBeditor bug? (access 2000 sr-1)

    You're setting breakpoints in VBA code but you're getting a ... what? A dialog? I don't know what the "Macro ..." window might be, unless it's the dialog you see when a macro breaks, and that has nothing to do with the VB editor.

    How are you setting the breakpoints if the VB editor isn't working? In Access 2000, it isn't always possible to break into code at points that allowed it in 97, but you haven't really explained what *is* happening.
    Charlotte

  3. #3
    New Lounger
    Join Date
    Jan 2001
    Location
    Maryland, USA
    Posts
    19
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: VBeditor bug? (access 2000 sr-1)

    Sorry, guess me explaination was kinda vague.

    The dialog box that pops up is the same as under Tools>Macros... I'm going to reload Access and hope this takes care of the problem.

  4. #4
    Plutonium Lounger
    Join Date
    Dec 2000
    Location
    Sacramento, California, USA
    Posts
    16,775
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: VBeditor bug? (access 2000 sr-1)

    Tools-->Macros gives you a submenu that lists the VBE and Macros. Are you saying that when you select the VBE, it doesn't open or that you get the Run Macro dialog instead? I never bother with the menu for that and you can't run code routines from the menu anyhow, so what behavior are you expecting that isn't happening?
    Charlotte

  5. #5
    WS Lounge VIP rory's Avatar
    Join Date
    Dec 2000
    Location
    Burwash, East Sussex, United Kingdom
    Posts
    6,280
    Thanks
    3
    Thanked 191 Times in 177 Posts

    Re: VBeditor bug? (access 2000 sr-1)

    Hi Lisa,
    If you're getting the Macros dialog appearing, I would guess you're trying to run some code that expects an argument? I think Access gets a little confused as you haven't given it any way of passing the argument to it, so it assumes you're trying to run something else, hence the macro dialog with all your subs that don't require arguments.
    Hope that helps.
    Regards,
    Rory

    Microsoft MVP - Excel

  6. #6
    3 Star Lounger
    Join Date
    Dec 2000
    Location
    Columbus, Ohio, USA
    Posts
    286
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: VBeditor bug? (access 2000 sr-1)

    Lisa: This problem happened to me just yesterday. What I had to do was set the breakpoint as normal, then exit the VBE and return to my form and run the code (from a button click) and all worked well. HTH.

  7. #7
    New Lounger
    Join Date
    Jan 2001
    Location
    Maryland, USA
    Posts
    19
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: VBeditor bug? (access 2000 sr-1)

    Thanks for your input. All as my code is doing is opening a form and going to the last record (to add). It's in the "on click" sub of a form button.

    Help specifies: Run Sub/UserForm or Run Macro -- Runs the current procedure if the cursor is in a procedure, runs the UserForm if a UserForm is currently active, OR RUNS A MACRO IF NEITHER THE CODE WINDOW NOR A USERFORM IS ACTIVE. (emphasis added)

    ...But my userform IS active and/or the cursor IS in the procedure.

    I've reinstalled A2K and still having the same problem. I am not new to Access, but have just upgraded to Access 2000.

  8. #8
    New Lounger
    Join Date
    Jan 2001
    Location
    Maryland, USA
    Posts
    19
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: VBeditor bug? (access 2000 sr-1)

    I'll bite... How do you change the breakpoint to "normal" ??? What am I missing? (other than a few million brain cells). <img src=/S/hairout.gif border=0 alt=hairout width=31 height=23>

  9. #9
    3 Star Lounger
    Join Date
    Dec 2000
    Location
    Columbus, Ohio, USA
    Posts
    286
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: VBeditor bug? (access 2000 sr-1)

    My post read, set the breakpoint as normal, or as you would normally set a breakpoint, i.e., in VBE, Debug, Toggle breakpoint. Exit from VBE and click your button. Your code should stop at the breakpoint. Sorry I was a little vague. HTH.

  10. #10
    New Lounger
    Join Date
    Dec 2001
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: VBeditor bug? (access 2000 sr-1)

    I believe that Access 2000 will only let you run a procedure in a *Module* in this manner. I get the same thing as you describe if I click in an event procedure (such as btnOK_Click): the Macros dialog pops up. I believe you will get the same dialog box even if you don't have any breakpoints set. I believe you will have to actually open the form in form view and click the button to run the Click event procedure. That is what I always have done.

    Another thing, from what I have seen a UserForm is different than an Access Form. In Help for the VBA Editor it says you can click Insert-->UserForm. But I don't see that menu there.. <img src=/S/confused.gif border=0 alt=confused width=15 height=20> I had a UserForm open once in the Editor but I don't recall how I got it there. I do remember that it looked more like the beginning of a Visual Basic form than an Access form. Hope this 2 cents helps.

  11. #11
    New Lounger
    Join Date
    Jan 2001
    Location
    Maryland, USA
    Posts
    19
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: VBeditor bug? (access 2000 sr-1)

    Greg, I do believe you are right. It just seemed so much easier in Access 97. <img src=/S/sigh.gif border=0 alt=sigh width=15 height=15> Thanks for your reply. <img src=/S/smile.gif border=0 alt=smile width=15 height=15>

  12. #12
    Plutonium Lounger
    Join Date
    Dec 2000
    Location
    Sacramento, California, USA
    Posts
    16,775
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: VBeditor bug? (access 2000 sr-1)

    Access does not use the same forms that the rest of Office and VB use. However, this has been true all along and isn't an artifact of Access 2000. The biggest change is in the VB IDE, which is very different in 2000 and looks and feels more like the IDE in VB and in the rest of Office. Once you get used to it, you may find you like it better--I know I did.
    Charlotte

Posting Permissions

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