469,907 Members | 2,178 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,907 developers. It's quick & easy.

How to raise the ValueChanged event only when move the track bar manually?

Hello,
I want to raise the ValueChanged event ONLY when i move the track bar
manually, but not the value changed, how to do in the event below? thank you

Private Sub TrackBar1_ValueChanged(ByVal sender As Object, ByVal e As
System.EventArgs) Handles TrackBar1.ValueChanged
End Sub

Sep 10 '08 #1
2 8326
On Sep 10, 2:10*pm, "Steven" <ga...@163.comwrote:
Hello,
I want to raise the ValueChanged event ONLY when i move the track bar
manually, but not the value changed, how to do in the event below? thank you

Private Sub TrackBar1_ValueChanged(ByVal sender As Object, ByVal e As
System.EventArgs) Handles TrackBar1.ValueChanged
End Sub
Then you need to handle "Scroll" event instead of "ValueChanged" event
which is raised when either a mouse or keyboard action moves the
scroll box.

http://msdn.microsoft.com/en-us/libr...ar.scroll.aspx

Hope this helps,

Onur Güzel

Sep 10 '08 #2
Thank you.

"kimiraikkonen" wrote:
On Sep 10, 2:10 pm, "Steven" <ga...@163.comwrote:
Hello,
I want to raise the ValueChanged event ONLY when i move the track bar
manually, but not the value changed, how to do in the event below? thank you

Private Sub TrackBar1_ValueChanged(ByVal sender As Object, ByVal e As
System.EventArgs) Handles TrackBar1.ValueChanged
End Sub

Then you need to handle "Scroll" event instead of "ValueChanged" event
which is raised when either a mouse or keyboard action moves the
scroll box.

http://msdn.microsoft.com/en-us/libr...ar.scroll.aspx

Hope this helps,

Onur Güzel

Sep 10 '08 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

2 posts views Thread by tshad | last post: by
3 posts views Thread by =?Utf-8?B?Ulc=?= | last post: by
1 post views Thread by Waqarahmed | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.