Loading video into existing movieclip

Hi all,
I am using the following code to load an external flv.
var video:Video = new Video();
addChild(video);
var nc:NetConnection = new NetConnection();
nc.connect(null);
var ns:NetStream = new NetStream(nc);
ns.client = {onMetaData:ns_onMetaData, onCuePoint:ns_onCuePoint};
function ns_onMetaData(item:Object):void {
// video.width = 370;
// video.height = 250;
video.x = 525;
video.y = 88;
function ns_onCuePoint(item:Object):void {
video.attachNetStream(ns);
ns.play("sfmekransu.flv");
But i want the movie to be loaded into my movie clip object that already created. How can i do it?

Hi,
add the video to your movieclip:
movieclip.addChild(video);
Warm Regards
Deepanjan Das
http://deepanjandas.wordpress.com/

Similar Messages

  • Load SWF into empty movieClip?

    Hello,
    Could anyone please point me in the right direction to find
    out how to load an external SWF into an already existing movieClip
    instance that is already placed on the stage? This is the way I've
    always worked in AS2, but I can't find how to do it in AS3. Can
    anyone point me to an example where URLRequest works with a
    specified movieClip instance?
    Thank you!

    I understand why you might think I was ignoring your advice,
    but this isn't the case. You're expertise is much valued and
    respected.
    My purpose for continuing to experiment with loading into a
    movieClip was an attempt to find an easy way to layer the SWF
    behind other elements, but as you know, although it works for this
    purpose, it doesn't allow control of the loaded SWF from the main
    timeline. For others struggling to learn as I am, here's a link
    where I found the answer to my question above:
    http://www.hostingforum.ca/776586-as3-controlling-loaded-swf.html
    The transition to AS3 is not as easy for some as for others,
    and there are new concepts to understand.
    Don't know what "nvm" means... curious, but might be better
    off not knowing ;) Thanks again for all the help you offer to all
    of us who are struggling.

  • Loading data into existing table

    Hi I have tried to load data into a large table from a csv file but am not getting any success. I have this control file
    LOAD DATA
    INFILE 'Book1.xls'
    BADFILE 'p_sum_bad.txt'
    DISCARDFILE 'p_sum_dis.txt'
    APPEND
    INTO TABLE p_sum
    FIELDS TERMINATED BY ',' OPTIONALLY ENCLOSED BY '"'
    TRAILING NULLCOLS
    SUMMARY_LEVEL ,
    PERIOD_START_TIME ,
    BUSY_HOUR ,
    OMC ,
    INT_ID ,
    BTS_ID ,
    BTS_INT_ID ,
    CELL_GROUP ,
    HO_PERIOD_DURATION ,
    POWER_PERIOD_DURATION ,
    MSC_I_SUCC_HO ,
    MSC_I_TCH_TCH ,
    MSC_I_SDCCH_TCH ,
    MSC_I_SDCCH ,
    MSC_I_TCH_TCH_AT ,
    MSC_I_SDCCH_TCH_AT ,
    MSC_I_SDCCH_AT ,
    MSC_I_FAIL_LACK ,
    MSC_I_FAIL_CONN ,
    MSC_I_FAIL_BSS ,
    MSC_I_END_OF_HO ,
    MSC_O_SUCC_HO ,
    The data is:
    2     3-Nov-06               1000033     9     8092220          1440     1440     5411     5374     7     30     5941
    2     3-Nov-06               1000033     10     1392190          1440     1440     0     0     0     0     0
    2     3-Nov-06               2000413     3     2127446          1440     1440     80     80     0     0     83
    2     3-Nov-06               2000413     4     2021248          1140     1440     0     0     0     0     0
    2     3-Nov-06               2000413     5     2021252          1080     1440     1     1     0     0     1
    2     3-Nov-06               2000413     6     2130163          1440     1440     2200     2193     2     5     2224
    2     3-Nov-06               2000413     7     6205155          1020     1440     0     0     0     0     0
    2     3-Nov-06               2000413     8     6200768          900     1440     30     30     0     0     31
    2     3-Nov-06               2000413     10     2111877          1440     1440     0     0     0     0     0
    2     3-Nov-06               1000033     18     1076419          1440     1440     75     73     0     2     79
    2     3-Nov-06               1000033     19     8089060          1440     1440     0     0     0     0     0
    but when I try to load the data, I get:
    Column Name Position Len Term Encl Datatype
    SUMMARY_LEVEL FIRST * , O(") CHARACTER
    PERIOD_START_TIME NEXT * , O(") CHARACTER
    Record 51: Rejected - Error on table OMC.P_SUM_BTS_HO_POWER, column SUMMARY_LEVEL.
    ORA-01722: invalid number
    I believe the data being loaded has to be NUMBER. Can anyone adivse what do I need to change to load the data. Thanks

    Justin,
    Tried that, no luck:
    Number to load: ALL
    Number to skip: 0
    Errors allowed: 50
    Bind array: 64 rows, maximum of 256000 bytes
    Continuation: none specified
    Path used: Conventional
    Table P_SUM, loaded from every logical record.
    Insert option in effect for this table: APPEND
    TRAILING NULLCOLS option in effect
    Column Name Position Len Term Encl Datatype
    SUMMARY_LEVEL FIRST * WHT O(") CHARACTER
    PERIOD_START_TIME NEXT * WHT O(") CHARACTER
    BUSY_HOUR NEXT * WHT O(") CHARACTER
    OMC NEXT * WHT O(") CHARACTER
    INT_ID NEXT * WHT O(") CHARACTER
    BTS_ID NEXT * WHT O(") CHARACTER
    BTS_INT_ID NEXT * WHT O(") CHARACTER
    CELL_GROUP NEXT * WHT O(") CHARACTER
    Record 51: Rejected - Error on table OMC.P_SUM_BTS_HO_POWER, column SUMMARY_LEVEL.
    ORA-01722: invalid number
    Any other sugesstion

  • How do I load photos and video into existing flash

    Hi,
    I can work with graphics and timeline keyframes but I'm
    generally clueless about scripting.
    I have a page:
    http://www.harmoniccycle.com/hc/swf/IMBA/pineyZ/PINEY_Z.html
    that I've prepared with 3 button instances in anticipation of
    loading either one of 2 photos or a video clip into a upper level
    I am terrible with the loadmovie syntax, and have tried
    loading the photos with a onrelease load movie script but keep
    getting error reports.
    I am also unclear as how best to unload the photos or video
    to get back to the lowest level timeline.
    I have Flash 8.
    I see you can load jpegs or .swf but t seems if I can learn
    to load .swfs I could then use the same load/unload solution to
    load either my photos (whcih I guess I would *embed* in a .swf) or
    the flash video (also as a .swf)
    thanks for any help you can offer,
    Mike McCue

    http://community.sony.com/t5/Cybershot-Cameras/Can-I-Change-Folder-Structure-on-Sony-DSC-WX50/m-p/57317#U57317
    KimberleyS's response may help
    Also make sure your folder structure in the camera is on Standard and not by Date

  • How? load imgaes into a movieclip

    Hi,
    I like to load some images into movieclip using actionscript. I am doing this because I use flex not flash. Does anybody know how it can be done?

    No, that would end up loading over what you already load since you have only the one Loader.  A single Loader can only hold a single loaded file.  So in your loop you need to create new loaders for each image.  You would need to use something more like...
    var myArray:Array = ["img1.jpgh","img2.jpg","img3.jpg","img4.jpgh","img5.jpg"];
    var mc:MovieClip = new MovieClip();
    for(var i=0; i<myArray.length; i++){
         var loadit:Loader = new Loader();
         loadit.load(new URLRequest(myArray[i]));
         mc.addChild(loadit);
    addChild(mc);
    The setInterval code you showed at the end will not work, mainly because the MovieClip you created dynamically does not have anything in frames that you could gotoAndPlay.

  • Down loading video into photoshop elements 9

    I'm all set to do this just how
    is this done? I have the camera beside me, a USB
    cable set to go. How do I set this up??

    I guess you are trying to import the videos from the camera into Elements.
    Just connect the camera to the PC using the USB cable. From the Windows Autoplay Entry, select the Photoshop Elements. In the resultant Downloader window click Get Photos.
    This will get your photos and videos in Organizer.
    BTW, can you please confirm the version 9 of PSE that you are using as the only latest version available till now is PSE 8 ?
    Thanks/ Tarun

  • Loading video into itnes

    Hi everyone
    I am trying to load some of my home movies into itunes so that I can play them over airplay
    but I can not figure out how to get the movies in there.
    Thank you for your time
    Uncle

    Drag them to the library in the open iTunes application window. You may need to use a tool such as MPEG Streamclip to convert them to MPEG-4 first.
    (118262)

  • Loading Data into existing Data Targets from 2 DataSources

    Hello:
    I want to report on COPA data. I am currently reporting on one Operating concern E.g 1_CO_PA_0001. Now i want to report on the Operating concern E.g 1_CO_PA_0004. For this i created a new DataSource. Replicated it into BW.
    My question is can i link the newly created COPA datasource (1_CO_PA_0004) with the Data Targets (ODS or Cube) of the of 1_CO_PA_0001 and load data? Will get any errors? or is this a big blunder i am doing?
    Can any one explain?
    Regards
    Lalitha

    If you are using Calc manager rules then have a look at the CalcMgrCmdLineLauncher.cmd utility -http://docs.oracle.com/cd/E17236_01/epm.1112/hp_admin/ch06s09s05.html
    If it is EAS rules then you could use the CmdLnLauncher utility to automate running rules.
    or you could create calc scripts and automate using Maxl.
    Cheers
    John
    http://john-goodwin.blogspot.com/

  • Loading videos into Itunes

    I have some video files that are not in a quick time format, so i wanted to use the convert selection to ipod feature, but whenever i try add the file to itunes it doesnt show up. Is there any way to do this or why doesnt it work? thanks, appreciated much

    Hey nat187,
    This article: http://docs.info.apple.com/article.html?artnum=304784#7 will show you the iTunes supported video formats.
    Jason

  • I am having a very bad time with loading videos into Keynote, which I have used for 7 years in medical lectures given all over the US and the world.  Yes there are a lot of slides with cine loops, but I have never had these crashes before.  A

    Is there anyone at Apple that I can talk to about this Keynote issue of losing sldes after saving?

    Sorry to say we folks are not HP employees and have no access to your service records so there is not much help we can provide other than moral support

  • How to Load new members into existing dimensions in Planning 9.3.1

    Hi,
    I am not having HAL, and is it possible to load members into existing dimensions of a newly created planning application - for example under accounts I want to add around 100 members - how to add them using a flat file without using HAL - is there anyother way out.
    Can we use workspace->Navigate ->administer->Dimention Library
    Create a new dimension here add that to Accounts ?? help me in this

    John,
    Can you suggest me the syntax to be used for the below example to create a flat file
    the Hiearchy I have(for accounts and entity)
    current:
    Accounts
    I need t have the following children under Accounts
    Child of Accounts:Assets,alias(assets of x company)
    Child of Asssets: 101, alias(asset1),Datastorage("store"), base currency("USD"),aggregation(+),Plantype("plan1")
    Regards,

  • Load different thumbnails into different movieclips

    I'm creating a gallery and having a problem loading thumbnails into different MovieClips. I have all the MCs stored into an Array. I could load them if I wanted to type out:
    var thumbLoader1:Loader = new Loader();
    movieClipName1.addChild(thumbLoader1);
    but I would think there's a more dynamic way. Right now Im stuck at:
    var imageThumbNames:Array = new Array
    function photoLoaded(event:Event):void
        trace ("photo loaded");
        trace (xmlData.Person.length());
        imageThumbNames[photoNumberLoaded] = "image" + photoNumberLoaded;
        var image:Bitmap = event.target.content as Bitmap;
        image.smoothing = true;
        thumbHolderArray[photoNumberLoaded].addChild(image);
        if (photoNumberLoaded < xmlData.Person.length() && photoNumberLoaded < numberOfThumbs)
            photoNumberLoaded += 1;
            addThumbs();
    I tried switcing the var "image" with a name from the "imageThumbNames" array but that would've been too easy. Any help is greatly appreciated.

    var thumbLoader1:Loader = new Loader();
    movieClipName1.addChild(thumbLoader1);
    var imageThumbNames:Array = [your image files];  // populate in for-loop
    var photoNumberLoaded:uint=0;
    addThumbs();
    function photoLoaded(event:Event):void
        trace ("photo loaded");
        trace (xmlData.Person.length());
        //imageThumbNames[photoNumberLoaded] = "image" + photoNumberLoaded;
        var image:Bitmap = event.target.content as Bitmap;
        image.smoothing = true;
    //not sure if this is the right thing to add to add these loaders to
        thumbHolderArray[photoNumberLoaded].addChild(mc.getChildAt(0));
    photoNumberLoaded += 1;
        if (photoNumberLoaded < xmlData.Person.length() && photoNumberLoaded < numberOfThumbs)
            addThumbs();
    var mc:MovieClip=new MovieClip();
    function addThumbs(){
    mc["loader_"+photoNumberLoaded]=new Loader();
    var urlR:URLRequest=new URLRequest(imageThumbNames[photoNumberLoaded]);
    mc["loader_"+photoNumberLoaded].addEventListener(Event.COMPLETE,photoLoaded);
    mc["loader_"+photoNumberLoaded].load(urlR);

  • Memory leak problems with loading videos over and over.

    I'm having memory leak problems with loading videos into a VideoPlayer aswell as FLVPlayback.
    What the flash should do:
    - Should be running for 7 days without having to restart the projector.
    - Interface that shows people around a 360 3D model with 5 different parts and at the stops it makes during the rotation you can click to zoom in on a location which plays a movie for that aswell.
    - Shows a video out of 5 parts for a 360 rotation in 3D in mp4 video (added each time and cleaned up, see code below).
    - Still images are used when the video clips are done playing (MovieClip in stage).
    - Should run automatically when there is no user interaction for X minutes.
    What the problem is:
    - The flash (as a exe and swf i guess) starts to consume memory over time (say 10 hours) until the projector crashes. This usually at around 1.75 GB of memory.
    I cannot see why the Flash cannot garbage collect this and free up the memory. Mabye there is something I don't understand about the garbage collection in flash?
    Here is some code from the video loading and playing:
    var fVideo:VideoPlayer;
    VideoCreate();
    function VideoReady(pEvent:VideoEvent):void
    trace("VideoReady()");
         // start playing video
    fVideo.play();
    function VideoLoad(pUrl:String):void
         trace("VideoLoad(" + pUrl +
         VideoCreate();
         if (pUrl != "")
              if (fVideoFolder + pUrl == fVideo.source)
                   fVideo.seek(0);
    VideoReady(null);
              } else {
    trace(fVideo.state);
                   if (fVideo.state !=
    VideoState.DISCONNECTED) fVideo.stop();
    fVideo.close();                                
    fVideo.load(fVideoFolder + pUrl);
         } else {
    // error no url
    function VideoCreate():void
         trace("VideoCreate()");
         // remove old one
         if (getChildAt(0) == fVideo)
              removeChildAt(0);
         fVideo = new
    VideoPlayer(1024, 768);
         addChildAt(fVideo, 0);
         fVideo.autoRewind = false;
    fVideo.addEventListener(VideoEvent.COMPLETE, VideoDonePlaying);
    fVideo.addEventListener(VideoEvent.READY, VideoReady);

    Hmm. It's in connection with Dropbox. Så apparantly you can only use one of the two at the same time if you want the programs integrated in Finder.

  • Loading video to 160gb classic

    I can't load video into my ipod library after its been ripped,  (istudio & DVD Magic). I have no problem ripping video formats but my library just wont accept it, (simple drag and drop), I already have a 60gb ipod that i have had no problem loading video. I then updated to the 160gb to fit more video but it won't accept the avi files video into my library. They play fine on my pc.

    I've just found out last night that iTunes does not allow videos not from the iTunes store. That's not a very good promotion for iTunes. Well, you can always try loading it into Windows Media Player, then dragging the file into your iPod on "Disk Mode".

  • How to dynamically load images into Flash

    I have a movie clip on the stage that I want to dynamically
    load images into (that constantly change), how would I go about
    doing this? Thanks.

    Use the Loader class to load in images.
    Then use addChild to add the Loader class into your MovieClip
    on the stage.
    As far as &amp;quot;constantly change&amp;quot; what
    do you mean by that? You could use setInterval, ther enterFrame
    event, or any other means to trigger a new image to be loaded into
    the Loader instance.
    Finally, you can use the Tween class to create some nice
    effects for the images (fade it, blur in, photo blend, masks,
    etc)

Maybe you are looking for