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 biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ControlTip Text Lookup 1

Status
Not open for further replies.

rccline

Technical User
Jun 13, 2002
341
US
Can I do a lookup for Controltip Text?

I want to show a controltip for a field in a query result.

Thanks.

Robert
 
You can only have ControlTips on forms. They can be set programmatically.
 
Yes. I understand that. I am refering to control tip in a form. But, I want to display the result of a query in the text as I move the mouse over the control on the form.

Robert
 
I have not tested, but you could try the mouse move event to set controltip text. It would need to be a very quick query indeed.
 
How do you set the control tip value for the result of the query?

A little more combersome, but alternatively, perhaps a command button to disply a message box that displays the result of the one-field query. The query produces number.

Thanks.

Robert
 
An example using DLookUp:

Code:
Private Sub txtText_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
Me.txtText.ControlTipText = Nz(DLookup("ID", "Table1", "Text='" & Me.txtText & "'"), "NA")
End Sub
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top