I want to make a label, and when you are in the process of click it, the caption says one thing, and then when you let go, it says what it had there before
Printable View
I want to make a label, and when you are in the process of click it, the caption says one thing, and then when you let go, it says what it had there before
Use the Mouse_Down and Mouse_Up event.
Why don't you useQuote:
If windows.crash = true then
load Unix
else
if Unix.Crash = true then
goto Burger King
end if
end if
[/code]
If windows.crash = true then
load Unix
elseif Unix.Crash = true then
goto Burger King
end if[/code]
Than you only gotta use one end if. :p
Here you go.
Code:Option Explicit
Private g_mCaption As String
Private Sub Form_Activate()
g_mCaption = Label1.Caption
End Sub
Private Sub Label1_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
Label1.Caption = "This is the temporary label"
End Sub
Private Sub Label1_MouseUp(Button As Integer, Shift As Integer, X As Single, Y As Single)
Label1.Caption = g_mCaption
End Sub
thanks, and I thought about that, but doesn't it mean that if the moue is moved on the thing from the top and bottem?
Dimiva, The Label1_MouseDown event will fire when you press any of your mouse buttons down on label1, while Label1_MouseUp will fire when you release the button
ok, thanks