|
-
May 17th, 2008, 09:05 AM
#1
Thread Starter
Addicted Member
[RESOLVED] Making a progressbar's length equal to music length ?
How can i make a progressbars length the same as the music's length ?
Like if the song is halfways the progressbar is halfways.
progress = progressbar1
player = axWindowsMediaPlayer
vb.net Code:
' Hardcoded maximum, because i know the length of the song...
Progress.Maximum = 269
' setting the value to the current time
Progress.Value = player.Ctlcontrols.currentPosition
But how do i loop it so it is synchronized with the song ?
Last edited by Link; May 18th, 2008 at 03:04 AM.
-
May 17th, 2008, 10:18 AM
#2
Re: [2008] Making a progressbar's length equal to music length ?
You'd Start a Timer and on every Tick you'd repeat that second line.
-
May 17th, 2008, 12:52 PM
#3
Thread Starter
Addicted Member
Re: [2008] Making a progressbar's length equal to music length ?
Nice thanks im looking into it...
But when im doing timer.enabled = true, i get some error saying System.NullReferenceException was unhandled, and a error on danish...
-
May 17th, 2008, 12:57 PM
#4
Frenzied Member
Re: [2008] Making a progressbar's length equal to music length ?
Try writing timer1.Enabled = True.
Please rate helpful ppl's posts. It's the best 'thank you' you can give 
-
May 17th, 2008, 01:28 PM
#5
Thread Starter
Addicted Member
Re: [2008] Making a progressbar's length equal to music length ?
i made the variable as timer so no But its fixed now, thanks for the help
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|