This of any use? http://tech.groups.yahoo.com/group/flexcomponents/message/1398
--- In [email protected], "Yair Flicker" <[EMAIL PROTECTED]> wrote: > > Hello people, > > I have a problem where I set the videoDisplay.source property to an > invalid URL - 404 - call the .play() method, and then the videoDisplay > simply says that it's loading. It doesn't give any indication of an > error, just sits there and says it's loading. It's the most annoying > thing in the world....how the hell am I supposed to know when the > .source property points to an invalid URL?!?!?! I even have a timer in > there to output the state of the VideoDisplay every 2.5 seconds - all it > says is that it's loading. Am I crazy? Am I doing something wrong? Or is > this a blatant bug in Flex? > > Try this MXML: > > <?xml version="1.0" encoding="utf-8"?> > <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" > <http://www.adobe.com/2006/mxml> layout="absolute"> > > <mx:Script> > <![CDATA[ > import mx.events.VideoEvent; > private function showInfo(event:VideoEvent):void { > trace('stateChange: ' + event.state + ' ' + event); > var foo:Timer = new Timer(2000, 100); > foo.addEventListener(TimerEvent.TIMER, timerComplete); > foo.start(); > } > private function timerComplete(event:TimerEvent):void { > trace('timerComplete: ' + vid.state + ' ' + event); > } > ]]> > </mx:Script> > > <mx:VideoDisplay id="vid" > source="http://sjc-v90.sjc.you1234tube.com/get_video? video_id=BTh8no91g5\ > 4E" <http://sjc-v90.sjc.you1234tube.com/get_video? video_id=BTh8no91g54E> > autoPlay="true" width="450" height="338" stateChange="showInfo (event)" > /> > > </mx:Application> > > > The trace debug output is as follows: > stateChange: loading [Event type="stateChange" bubbles=false > cancelable=false eventPhase=2] > timerComplete: loading [TimerEvent type="timer" bubbles=false > cancelable=false eventPhase=2] > timerComplete: loading [TimerEvent type="timer" bubbles=false > cancelable=false eventPhase=2] > ................ > timerComplete: loading [TimerEvent type="timer" bubbles=false > cancelable=false eventPhase=2] > timerComplete: loading [TimerEvent type="timer" bubbles=false > cancelable=false eventPhase=2] > > And btw, if you set the source to > http://chi-v45.chi.youtube.com/get_video?video_id=n4Fwge2iqJ0 > <http://chi-v45.chi.youtube.com/get_video?video_id=n4Fwge2iqJ0> > (another 404), Flex detects it immediately and the trace output is what > you would expect/hope. > > Anybody else experience this problems? Can anybody think of any > fixes/workarounds? Am I doing something wrong? Thanks! >

