Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

[b]ControlTip Text in Switchboard (Can they be changed)[/b]

Status
Not open for further replies.

8177

Programmer
Aug 6, 2003
25
GB
Hi Guys

Does anybody know if you can change the ControlTip Texts within the switchboards depending on which switchboard you are looking at

If so how?
 
Yes. Building on the structure that Access gives you when you create a Switchboard you could add a field to the table [tt]Switchboard Items[/tt] called [tt]ControlTip[/tt]. Then in the form module make the following changes to [tt]FillOptions()[/tt]:
Code:
Private Sub FillOptions()
...
  ' If there are no options for this Switchboard Page,
  ' display a message.  Otherwise, fill the page with the items.
  If (rs.EOF) Then
      Me![OptionLabel1].Caption = "There are no items for this switchboard page"
  Else
      While (Not (rs.EOF))
          Me("Option" & rs![ItemNumber]).Visible = True
          [b]Me("Option" & rs![ItemNumber]).ControlTipText = rs![[i]ControlTip[/i]][/b]
          Me("OptionLabel" & rs![ItemNumber]).Visible = True
          Me("OptionLabel" & rs![ItemNumber]).Caption = rs![ItemText]
          rs.MoveNext
      Wend
  End If
...
End Sub

Hope this helps,
CMP


(GMT-07:00) Mountain Time (US & Canada)
 
Thanks for this its a great help

Malc


 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top