access switchboards

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

if i "nest" switchboards that I have access to create, is there a way change
the appearance on each of them or will they all have to look the same? Also,
is there a way to run a query from a switchboard?
 
If you use the standard Access Switchboard Wizard, you are stuck with
the standard appearance for all your switchboards. In fact, there is
only one switchboard Form in your database - each instance is
populated with text and buttons "on the fly" from a Table which
contains the information you entered in the Switchboard Manager. If
you want to vary the appearance of your switchboards, you have to
create them yourself, though a few things can be done by playing with
the Access Switchboard Form and data Table.

if i "nest" switchboards that I have access to create, is there a way change
the appearance on each of them or will they all have to look the same? Also,
is there a way to run a query from a switchboard?


Please respond to the Newsgroup, so that others may benefit from the exchange.
Peter R. Fletcher
 
if i "nest" switchboards that I have access to create, is there a way change
the appearance on each of them or will they all have to look the same? Also,
is there a way to run a query from a switchboard?

There is only one Switchboard form if you have used the built-in
switchboard manager to create your form. However, you could change
label text (or make labels visible or not visible), as well as change
the switchboard form color by code, depending upon the SwitchboardID
number.

Add code to the Private Sub FillOptions() Sub Procedure.

If Me!SwitchboardID = 2 Then
Me.Section(0).BackColor = vbRed
Label1.Caption = "Reports"
Label2.Caption = "Reports"
ElseIf Me!SwitchboardID = 3 Then
Me.Section(0).BackColor = vbGreen
Label1.Caption = "Queries"
Label2.Caption = "Queries"
Else
Me.Section(0).BackColor = -2147483633
Label1.Caption = "Forms"
Label2.Caption = "Forms"
End If

Change the colors and captions as wanted.

Running a query is not directly supported by the Access switchboard
manager. You can either add a new Constant to the Sub Procedure, or
simply use Run Code or run Macro (which the manager can do) to run a
code module or a macro, that in turn opens the query.

Your best bet, however, is to create your own forms with command
buttons to use as switchboard. If you use the Command Button wizard,
Access will write most of the code for you.
You'll have much more control and maintenance will be much easier.
 
Back
Top