Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

progress bar click => change current track play position

i am making a music player in winforms. i have a progress bar and when i click on a position along the progress bar, i want to get the int for that position ( from 1 to 100 , i.e. for when i want to get to a certain point in my song ) . How can i do that ?

Regards, Alexandru Badescu

like image 781
Alex Avatar asked Jan 29 '26 06:01

Alex


2 Answers

Use TrackBar control, and this is may an advance one, I hope it helps you.

Good luck.

like image 143
Homam Avatar answered Jan 31 '26 21:01

Homam


Try this:

'Using The Click or MouseDown or any Mouse Event

Dim Value As Integer= Me.PointToClient(MousePosition).X-Progressbar.Bounds.X

Progressbar.value= Value
like image 41
Amateur Avatar answered Jan 31 '26 22:01

Amateur



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!