Quantcast
Channel: VBForums
Viewing all articles
Browse latest Browse all 42316

VS 2010 Button Click continously call function

$
0
0
Hello,

I am trying to use a button to continuously call a function as long as I hold the button down. Below is what I have so far but It only calls the function once even if I hold button clicked down.



Private Sub Button3_MouseDown(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles Button3.MouseDown
If SerialPort1.IsOpen() = False Then
SerialPort1.Open()
End If

sendA()


End Sub



Thank you

Viewing all articles
Browse latest Browse all 42316

Trending Articles