我一直在互联网上找到解决方案,但我没有看到任何与我的问题完全相同的内容
如果选择了btn2,如何让btn1停止悬停?
这是我想到的流程,但我无法编码
if btn1 = selected or clicked then
btn2.image = my.resources.btn2image_disabled
then btn2 hover stop 'bec this one have a hover property and mouseleave property
or i've been thinking of
btn1 click property
btn1.clicked = true
if btn1.clicked = true then
btn2 hover stop and mouseleave stop
end if
顺便说一下,这里的代码非常基本。
Private Sub btn_encrypt_fbrowse_MouseLeave(sender As Object, e As EventArgs) Handles btn_encrypt_fbrowse.MouseLeave
btn_encrypt_fbrowse.Image = My.Resources.btn_fbrowse
End Sub
Private Sub btn_encrypt_fchange_MouseEnter(sender As Object, e As EventArgs) Handles btn_encrypt_fchange.MouseEnter
btn_encrypt_fchange.Image = My.Resources.btn_fchange_hover
End Sub
Private Sub btn_encrypt_fchange_MouseLeave(sender As Object, e As EventArgs) Handles btn_encrypt_fchange.MouseLeave
btn_encrypt_fchange.Image = My.Resources.btn_fchange
End Sub
Private Sub btn_encrypt_fencrypt_MouseEnter(sender As Object, e As EventArgs) Handles btn_encrypt_fencrypt.MouseEnter
btn_encrypt_fencrypt.Image = My.Resources.btn_fencrypt_hover
End Sub
Private Sub btn_encrypt_fencrypt_MouseLeave(sender As Object, e As EventArgs) Handles btn_encrypt_fencrypt.MouseLeave
btn_encrypt_fencrypt.Image = My.Resources.btn_fencrypt
End Sub
当点击加密时,解密将变为禁用并停止悬停和mouseleave属性,这适用于其他按钮(dev,help,faqs),不包括about按钮因为弹出另一个表单。
这是我的按钮