Gruppe
Ereignis
Problem
Beim Überfahren der Schaltflächen mit der Maus sollen Ampelfarben angezeigt werden.
ClassModule: Tabelle1
Private Sub CommandButton1_MouseMove( _
ByVal Button As Integer, _
ByVal Shift As Integer, _
ByVal X As Single, _
ByVal Y As Single)
CommandButton1.BackColor = vbRed
CommandButton2.BackColor = vbWhite
CommandButton3.BackColor = vbWhite
End Sub
Private Sub CommandButton2_MouseMove( _
ByVal Button As Integer, _
ByVal Shift As Integer, _
ByVal X As Single, _
ByVal Y As Single)
CommandButton1.BackColor = vbWhite
CommandButton2.BackColor = vbYellow
CommandButton3.BackColor = vbWhite
End Sub
Private Sub CommandButton3_MouseMove( _
ByVal Button As Integer, _
ByVal Shift As Integer, _
ByVal X As Single, _
ByVal Y As Single)
CommandButton1.BackColor = vbWhite
CommandButton2.BackColor = vbWhite
CommandButton3.BackColor = vbGreen
End Sub
Private Sub Label1_MouseMove( _
ByVal Button As Integer, _
ByVal Shift As Integer, _
ByVal X As Single, _
ByVal Y As Single)
CommandButton1.BackColor = vbWhite
CommandButton2.BackColor = vbWhite
CommandButton3.BackColor = vbWhite
End Sub
StandardModule: Modul1
Sub Dummy()
End Sub