Solved

Access VBA debug - make switchboard appear for user entry

Posted on 2012-03-13
6
536 Views
Last Modified: 2012-06-21
I am attempting to debug Access VBA code. When I set a breakpoint and choose Debug > Run to breakpoint nothing happens.  I need for the Switchboard to appear so that choices can be entered to progress through the code.  What's the magic word?   (Alt + F11 simply toggles to the Switchboard in design mode.)

thanks
0
Comment
Question by:lsmoore
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
6 Comments
 
LVL 77

Expert Comment

by:peter57r
ID: 37715464
I'm not clear from your description what is happening.

Are you saying that the code is not running or that the code is running but not stopping at the breakpoint, or something else.

Have you UNchecked the option 'Use Access Special Keys' in the startup options?  If so , that will prevent the Breakpoint from working.
0
 

Author Comment

by:lsmoore
ID: 37715518
The breakpoint is set (red line). I click Run to Cursor and nothing seems to happen.  Click F8 and I get a beep. I think the program is awaiting the user to make Switchboard choices, but I can't see the Switchboard.

Where is the "Use Access Special Keys"?
0
 

Author Comment

by:lsmoore
ID: 37715609
Incidentally, I've taken over someone else's project here.  When I click RUN, all I see are some Macros.  There does not seem to be an option run Run Form.  

thanks
0
PeopleSoft Has Never Been Easier

PeopleSoft Adoption Made Smooth & Simple!

On-The-Job Training Is made Intuitive & Easy With WalkMe's On-Screen Guidance Tool.  Claim Your Free WalkMe Account Now

 
LVL 77

Expert Comment

by:peter57r
ID: 37715738
A breakpoint is indicated by a BROWN blob in the left margin.  
RED code would indicate a syntax error in the code.

To single step through the code, first clcik the Reset button to be sure nothing is pending.
Then click into the procedure you want to run. And then press F8.  The procedure name should go yellow and you can then use F8 to step through the code.

If you still have a problem, you will have to post the code to get proper help.
0
 
LVL 74

Accepted Solution

by:
Jeffrey Coachman earned 500 total points
ID: 37715841
Again, your ultimate question here is not clear...

Typically the switchboard is set to open when the DB opens, via the Autoexec Macro.

So before you start worrying about things like Breakpoints, ...
Lets make sure:
That you even have a switchboard form?
If so, can yo see it in the database window/Task Pane?
If yes, then can you open it on it's own?
If yes, then do you have an Autoexec Macro?
If so what happens when you run it.
0
 

Author Closing Comment

by:lsmoore
ID: 37716176
On my computer the breakpoint code line is bright red backcolor, with a red dot beside in the left margin.  (Code error shows red text.)
To make this debug work properly I had click VIEW OBJECT, then VIEW > FORM VIEW.  This displayed the Switchboard awaiting entry, and execution stopped at the breakpoint, as I wanted.

thanks for your help.
0

Featured Post

Salesforce Made Easy to Use

On-screen guidance at the moment of need enables you & your employees to focus on the core, you can now boost your adoption rates swiftly and simply with one easy tool.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Omit After Update event 5 46
Calculate Weeks in A "Fiscal Month" 8 64
Best way to get data into a database 12 56
Access VBA for Search Engine 7 9
In earlier versions of Windows (XP and before), you could drag a database to the taskbar, where it would appear as a taskbar icon to open that database.  This article shows how to recreate this functionality in Windows 7 through 10.
Access custom database properties are useful for storing miscellaneous bits of information in a format that persists through database closing and reopening.  This article shows how to create and use them.
Using Microsoft Access, learn some simple rules for how to construct tables in a relational database. Split up all multi-value fields into single values: Split up fields that belong to other things into separate tables: Make sure that all record…
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question