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

Hover Effect 1

Status
Not open for further replies.

LakotaMan

Instructor
Aug 21, 2001
240
US
Hi All.
Using ver. 2007, I would like to have a label change bg color when the mouse moves over it and then return to its usual color when the mouse moves away. I have used the MouseMove event to achieve the first part of my wish, but the color stays, and after searching the postings, have not found a solution.
Any thoughts?
Thanks in advance,
LM
 
I have done this with code in the form (or whatever is around the label) to change the effect back to normal.
Code:
Private Sub Detail_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
    If Me.lblContinue.SpecialEffect <> 0 Then
        Me.lblContinue.SpecialEffect = 0
    End If
End Sub

Private Sub lblContinue_Click()
    DoCmd.OpenForm "frmMainMenu"
    DoCmd.Close acForm, Me.Name
End Sub

Private Sub lblContinue_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
    If Me.lblContinue.SpecialEffect <> 3 Then
        Me.lblContinue.SpecialEffect = 3
    End If
End Sub

Duane
Hook'D on Access
MS Access MVP
 
Duane,

Sorry to tak so long to get to this, works beautifully!

Thanks so much for the help!

Have a star.
LM
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top