How to place titles on individual access switchboards

W

wd

I want to place titles on each switchboard as a description of the options on
that particular page (form).
 
T

Tom Wickerath

It sounds like you are using a switchboard that was created using the
Switchboard Manager. Is this correct? If so, you can open the Switchboard
Items table and look at the data. Notice that when the ItemNumber value is 0,
the corresponding ItemText becomes the caption of the switchboard form.

If you'd like to provide more information that is shown in the form's
caption, you can make the following modifications:

1.) Add a field to the Switchboard Items table named "ItemDescription"
(without the quotes). Make it a text datatype, with a Field Size setting of
255. Add appropriate descriptive text to the records where ItemNumber = 0.
This cannot be done using the Switchboard wizard, since it won't recognize
this new field.

2.) Add a textbox to the Switchboard form named "txtMyDesc".

3.) Add the following line of code (see <---New line below) to the
Form_Current event procedure of the Switchboard form:

Private Sub Form_Current()
' Update the caption and fill in the list of options.

Me.Caption = Nz(Me![ItemText], "")
Me.txtMyDesc = Nz(Me![ItemDescription], "") <---New line
FillOptions

End Sub


Tom
_____________________________________

:

I want to place titles on each switchboard as a description of the options on
that particular page (form).
 
J

Jeff Conrad

in message:
I want to place titles on each switchboard as a description of the options on
that particular page (form).

I believe some of the control names and code are different across
the various Access versions, but are you wanting to change the label
at the top of the form or the form caption itself?

Just tell the label caption and form caption to change with the menu like so:

Private Sub Form_Current()
' Update the caption and fill in the list of options.

Me.Caption = Nz(Me![ItemText], "")
Me.Label1.Caption = Nz(Me![ItemText], "")
FillOptions

End Sub
 
Top