Autor Beitrag
Starfighter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 51



BeitragVerfasst: So 11.05.03 12:04 
Wie kann ich bei mediaplayer eine "Trackbar" einbauen? Also so dsa ich in die mitte des mp3 gehen kann etc..
Ich glaub ihr wisst was ich meine!!
Mike_C
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 207

Win XP
D7 Enterprise
BeitragVerfasst: So 11.05.03 12:27 
naja, der MediaPlayer hat eine Property Length und eine Property Postition. der Trackbar übergibst du als MaxValue einfach die Länge des MP3-Files. beim ChangeEvent von der Trackbar übergibst du dann die Position der Trackbar dem MediaPlayer und springst an diese Position im MP3-File (also als StartPos)

pseudo-code mäßig meine ich das so:

Trackbar.Max = MediaPlayer.Länge des MP3-Files (über Length)

und TrackbarChange:
MediaPlayer.StartPosition = Trackbar.Position
MediaPlayer.Play

Wie das dann im richtigen Code aussieht, musst du dir zusammenbasteln.

_________________
Life is, what some people call a mystery. To me life's just a lesson, you're learning when you're through. So why do we try to understand?