# FlV player help

**URL:** <https://forum.kirupa.com/t/flv-player-help/225853>\
**Category:** flash\
**Created:** [May 16, 2007, 7:15am UTC](https://forum.kirupa.com/t/flv-player-help/225853 "2007-05-16T07:15:04Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![gimmig](https://avatars.discourse-cdn.com/v4/letter/g/cc9497/32.png) [@gimmig](https://forum.kirupa.com/u/gimmig)\
**Post date:** [May 16, 2007, 7:15am UTC](https://forum.kirupa.com/t/flv-player-help/225853/1 "2007-05-16T07:15:04Z")

</div>

Hi,  
i am trying to build a moviplayer and my problem is that i can´t get the timebar going.  
heres the code:

```php
_root.media.volumeBar = volBar;
// Streaming status

var loaded_interval:Number = setInterval(checkBytesLoaded, 500, _root.media);
function checkBytesLoaded(media:NetStream) {
//Gibt den Streaming-Status in % wieder
var pctLoaded:Number = Math.round(_root.media.bytesLoaded / _root.media.bytesTotal * 100);
//hier width of the Streaming-bar

streaming_bar._width = (pctLoaded * 2.35);
if (pctLoaded >= 100) {
clearInterval(loaded_interval);
}
}
//play und Pause Button
btn.onRelease = function() {
    if (moviePlaying == false){
	 _root.media.play();
	 moviePlaying = true
	}
	else{
		_root.media.pause();
		moviePlaying = false
	}
}

//timebar function

var duratio:Number;
_root.media.onMetaData = function(obj:Object){ 
  duratio=obj.duration; 
}
auto=setInterval(function():Void{
		var finalTime:Number=duratio;
		var finalWidth:Number = 238;
		var movVar:Number = finalWidth/finalTime;
		fortschritt._width = movVar*_root.media.time;
},10);

```

Something is wrong with the timebar function, I can´t find it  
Anybody out there who does?

Thanks

Niel
