• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

loading FLV problem (NetStream)

Participant ,
Dec 01, 2011 Dec 01, 2011

Copy link to clipboard

Copied

Hi all,

I'm having some problems loading a FLV and I've been searching on google for 2 days now and I can't seem to find a anwser for my problem, maybe one of you guys can help me out here.

here is the scenari I have a SWF that loads a FLV

code:

var videoConnection:NetConnection = new NetConnection();

videoConnection.connect(null);

var videoStream:NetStream = new NetStream(videoConnection);

var video:Video = new Video();

videoStream.play("myVideo.flv");

video.attachNetStream(videoStream);

video.width = 720;

video.height = 480;

video.x = 0;

video.y = 0;

loaderVid_mc.x = 152;

loaderVid_mc.y = 144;


The problem is everytime I try to load the video I get the following error message:

Error #2044: Unhandled AsyncErrorEvent:. text=Error #2095: flash.net.NetStream was unable to invoke callback onXMPData. error=ReferenceError: Error #1069: Property onXMPData not found on flash.net.NetStream and there is no default value.

          at content_fla::MainTimeline/frame1()

Anyone? Any ideas?

TOPICS
ActionScript

Views

2.9K

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Participant , Dec 01, 2011 Dec 01, 2011

Thanks very much for your HELP....I was looking at the help.adobe website you sent me and found a anwser for my problem.

In case anyone comes to the same problem here is what I did for solving it.

I just added the following lines to my code:

original

var videoConnection:NetConnection = new NetConnection();

videoConnection.connect(null);

var videoStream:NetStream = new NetStream(videoConnection);

var video:Video = new Video();

videoStream.play("myVideo.flv");

video.attachNetStream(videoStream);

new lines:

v

...

Votes

Translate

Translate
Community Expert ,
Dec 01, 2011 Dec 01, 2011

Copy link to clipboard

Copied

Basically you need NetStream.client set to an Object, which has onXMPData property that assigned to a function (or null if you don't want to do anything with XMP.) Have a look at the doc:

http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flash/net/NetStream.html#client

--

Kenneth Kawamoto

http://www.materiaprima.co.uk/

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Participant ,
Dec 01, 2011 Dec 01, 2011

Copy link to clipboard

Copied

LATEST

Thanks very much for your HELP....I was looking at the help.adobe website you sent me and found a anwser for my problem.

In case anyone comes to the same problem here is what I did for solving it.

I just added the following lines to my code:

original

var videoConnection:NetConnection = new NetConnection();

videoConnection.connect(null);

var videoStream:NetStream = new NetStream(videoConnection);

var video:Video = new Video();

videoStream.play("myVideo.flv");

video.attachNetStream(videoStream);

new lines:

var customClient:Object = new Object();

videoStream.client = customClient;

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines