# Problem with FLV component

**URL:** https://forum.kirupa.com/t/problem-with-flv-component/245269
**Category:** flash
**Created:** [November 28, 2007, 4:20am UTC](https://forum.kirupa.com/t/problem-with-flv-component/245269 "2007-11-28T04:20:22Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![rondog](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/rondog/32/2478_2.png) [@rondog](https://forum.kirupa.com/u/rondog)
#### Post date: [November 28, 2007, 4:20am UTC](https://forum.kirupa.com/t/problem-with-flv-component/245269/1 "2007-11-28T04:20:22Z")

</div>

I am loading some video in through xml and when I run the function that plays the video I get the error: Unable to make connection to server or to find FLV on server.

My flv component is inside of a movieClip ( for attachMovie purposes ) vidPlayer is the instance name of the actual component.

```php

function loadVid(itemID:Number, target:Number) {
    var src = projXML.firstChild.childNodes[target].childNodes[itemID].attributes.src;
    var width = projXML.firstChild.childNodes[target].childNodes[itemID].attributes.width;
    var height = projXML.firstChild.childNodes[target].childNodes[itemID].attributes.height;
    var vidClip = _root.createEmptyMovieClip("vidHolder", 5687);
    vidClip.attachMovie("vidMC","vidMC",5888);
    var connection:NetConnection = new NetConnection();
    connection.connect(null);
    var stream:NetStream = new NetStream(connection);
    vidClip.vidPlayer.attachVideo(stream);
    vidClip.vidPlayer.play(src); 
}

```
