Switchboard Manager

  • Thread starter Thread starter sharon
  • Start date Start date
I don't think the switchboard manager support a function to run queries.

Rick B


How do you set a switchboard to select different queries?
 
I never use 'Switchboards' because the wizard and template are too limiting. I just build them as regular Forms

- Create a new Form in Design View
- Add a Command Button to the Form
- Double-click on the Command Button to get the Properties window
- Click on the Events tab
- Right-click In the line for OnClick, select Build and then select either MacroBuilder (to build a macro that will run when the Command Button is clicked and, using the OpenQuery action, the macro can run your query) or CodeBuilder (to write the VBA code yourself to run the query)

Play with it a little bit and you'll be surprised at just how much you can do how easily

Hope this helps

Howard Brod



----- sharon wrote: ----

How do you set a switchboard to select different queries
 
How do you set a switchboard to select different queries?

Your best bet, for the long run, would be to scrap the built-in
switchboard for one of your own making, using command buttons. You'll
have better control of it's functionality and appearance. Had you been
using your own switchboard, you would not have needed to ask this
question.

The built-in switchboard does not directly support running queries.
However, if you create a Public sub-procedure (in a module), you can
then use the switchboard manager to set the command line to Run Code
using the procedure name where indicated.
The code to be used within in the procedure is:
DoCmd.OpenQuery "QueryNameHere"

Or you can create a macro set to the OpenQuery action, and use the
manager to set the command line to Run Macro.
 
Create one or more functions that open your queries, then use the
RunCode option in Switchboard Manager to run your functions.

Hope this helps,

Peter De Baets
Peter's Software - MS Access Tools for Developers
http://www.peterssoftware.com
 
Thank you Howard this works like a charm.
-----Original Message-----
I never use 'Switchboards' because the wizard and
template are too limiting. I just build them as regular
Forms.
- Create a new Form in Design View.
- Add a Command Button to the Form.
- Double-click on the Command Button to get the Properties window.
- Click on the Events tab.
- Right-click In the line for OnClick, select Build and
then select either MacroBuilder (to build a macro that
will run when the Command Button is clicked and, using
the OpenQuery action, the macro can run your query) or
CodeBuilder (to write the VBA code yourself to run the
query).
Play with it a little bit and you'll be surprised at
just how much you can do how easily.
 
Back
Top