Switchboard and subforms

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

Guest

Any help would be gratefully appreciated - I will try to be as specific about
my problem as possible:

I have a switchboard which has 8 options down the left hand side of the
switchboard form. Examples include 'Add Employee', 'Add Manager', 'Add New
Task' etc. I have also designed simple sub-forms for each of the options
included on the Switchboard.

To simplify navigation for my database, I would like the user to click on
these options and the sub-form opens / nests WITHIN the switchboard (i.e. not
on a new form, but within the existing form), similar to the manner of
'frames' within HTML / web pages. Clicking on other options will 'overwrite'
the sub-form with the appropriate form selected.

Hope someone can help!
 
To simplify navigation for my database, I would like the user to click on
these options and the sub-form opens / nests WITHIN the switchboard (i.e. not
on a new form, but within the existing form), similar to the manner of
'frames' within HTML / web pages. Clicking on other options will 'overwrite'
the sub-form with the appropriate form selected.

Try putting a subform on the main form and making it visible or not based
on the main form menu choices. You could have multiple subforms and
select which one to make visible based on the main menu selection too.

Tom Lake
 
Tom Lake said:
Try putting a subform on the main form and making it visible or not based
on the main form menu choices. You could have multiple subforms and
select which one to make visible based on the main menu selection too.

Tom - thanks for that. I've used the guidance from microsoft:

http://support.microsoft.com/defaul...port/kb/articles/Q209/6/89.asp&NoWebContent=1

but it doesn't quite do what I need. What I need is when the first button
is pressed, it shows SubForm A. Pressing the next button shows SubFormB.
Pressing the first button again shows SubForm A.

Unfortunately, the above 'fix' doesn't quite work - pressing the first
button shows SubForm A (OK), pressing the next button shows SubForm B (OK),
but when pressing the first button again, you have to press the second button
first to 'hide' SubForm B before it shows SubForm A. Does the make sense?
 
Create an unbound subform on your switchboard and then in the On Click
property of each button, define the .ControlSource property of the unbound
subform to be whatever subform you want opened.
 
Tom - thanks for that. I've used the guidance from microsoft:

http://support.microsoft.com/defaul...port/kb/articles/Q209/6/89.asp&NoWebContent=1

but it doesn't quite do what I need. What I need is when the first button
is pressed, it shows SubForm A. Pressing the next button shows SubFormB.
Pressing the first button again shows SubForm A.

Of course in each button's On Click event, you need to
explicitly hide the forms you're not using and show the
form you want.

Sub Button1_OnClick()
SF1.Show
SF2.Hide
SF3.Hide
SF4.Hide
End Sub

Sub Button2_OnClick()
SF1.Hide
SF2.Show
SF3.Hide
SF4.Hide
End Sub

Sub Button3_OnClick()
SF1.Hide
SF2.Hide
SF3.Show
SF4.Hide
End Sub

etc., etc.

Tom Lake
 
Have you though about using the switchboard's multi-screen capability to do
it without subforms?

Just add to your table Switchboard Items. Here is a partial list from a
Training database Switchboard Items table.
SwitchboardID ItemNumber ItemText Command Argument
1 0 Main Switchboard 0 Default
1 1 Main Menu 0
1 2 Training Information 1 5
1 3 Education Information 1 2
1 4 Reports 1 3
1 5 Search for Information 1 4
1 6 Employee Update 1 8
2 0 Education Information 0
2 1 Education Information 0
2 2 Educational Assistance 3 frm EduAsst Mainform
2 3 Return to Main Menu 1 1
3 0 Reports 0
3 1 Reports 0
3 2 Employee Training Records 1 7
3 3 Certification Reports 1 6
3 4 OMC Status (by Section and Employee) 4 rpt O&M Status
3 5 Completed Monthly Training Report 3 Monthly Training Status
3 6 Statistical Reports 3 Certifications by Month
3 7 Educational Assistance Reports 1 9
3 8 Return to Main Menu 1 1
 
Back
Top