Creating my own Switchboard

C

CarolM

Hi

I dont know if this is even possible but i would like to create my own switchboard. I have a graphic of a flower which i want to be the main background. I can then add in either command buttons or links to the rest of the database.

Is this at all possible, and if it is, any advice would be gratefully received.

Thanks

Carol
 
L

Larry Daugherty

Hi Carol,

A switchboard form is just a form with a lot of command buttons and labels.
The switchboard manager that MS provides with Access is a little more
sophisticated in that it is generalized to handle a wide range of uses.
However, their switchboards offer limited choices. When you create your own
you can do what you want directly from the switchboard.

HTH
--
-Larry-
--

CarolM said:
Hi

I dont know if this is even possible but i would like to create my own
switchboard. I have a graphic of a flower which i want to be the main
background. I can then add in either command buttons or links to the rest
of the database.
 
U

UpRider

The code below is a complete switchboard solution for me. I have 20 forms
in my database, and it's the only form navigation code that I need.

HTH
UpRider

The three examples are for the Click Event Procedure for a command button on
a form

'Example to swap to a new form and closing the calling form:
Private Sub cmdExit_Click()
Call subSwapForm("frmMiscMaintSwitch", , "Close")
End Sub

'Example to swap to a new form, setting the focus to a control on that form,
and hiding the current form:
Private Sub cmdMemberMaint_Click()
Call subSwapForm("frmDataEntry", "cboNameSearch")
End Sub

'Example to swap to a new form, hiding the current form:
Private Sub cmdSetup02_Click()
Call subSwapForm("frmSetup02")
End Sub

'The three above subs must be in a form's code; i.e. subSwapForm must ALWAYS
be called from a form
'The sub below must NOT be in a form's code, but in a module

Sub subSwapForm(GetForm As String, Optional ToControl As String, Optional
Disp As String)
Dim i As Integer, IsLoaded As Integer
IsLoaded = False
If UCase(Disp) = "CLOSE" Then
Dim cf As Form
Set cf = Screen.ActiveForm
DoCmd.Close acForm, cf.Name
Set cf = Nothing
Else
Screen.ActiveForm.Visible = False
End If
For i = 0 To Forms.Count - 1
If Forms(i).FormName = GetForm Then
IsLoaded = True
Exit For
End If
Next
If IsLoaded = True Then
Forms(i).Visible = True
Else
DoCmd.OpenForm GetForm
End If
If Len(ToControl) > 0 Then DoCmd.GoToControl ToControl
End Sub

CarolM said:
Hi

I dont know if this is even possible but i would like to create my own
switchboard. I have a graphic of a flower which i want to be the main
background. I can then add in either command buttons or links to the rest
of the database.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top