Load external and give instance name

I'm using this code to load and external swf, now how do I assign an instance name for it?
var eventInitialLoader:Loader = new Loader();
var eventInitialURL:String = parent['eventPath'+ie];
var eventInitialRequest:URLRequest = new URLRequest(eventInitialURL);
eventInitialLoader.load(eventInitialRequest);
eventOdd_MC.addChild(eventInitialLoader);
Thanks for helping!

At some point in your code you must have a reference to the instance you want to remove, then you can just do:
[instance].parent.removeChild([instance]);
or set up an array:
var instanceArr:Array = new Array();
and when you load a new instance with the Loader, do:
instanceArr.push(myInstance);
and to access them:
for (var i:uint = 0; i < myInstance; i++){
var child = instanceArr[i];
(do stuff with child)
child.parent.removeChild(child);

Similar Messages

  • I have tried to re-instal Adobe reader on my Mac many times. Asks for my PW and gives my name. I just received a new PW with no success. I delete my name and put in my E-mail address. No help.

    Cannot re-install Adobe reader. Says "Adobe reader wants to make changes" and gives my name not e-mail address then asks for a PW. I received a new PW and can sign into Adobe.com but am unable to install Adobe reader on my MAC.

    Enter the password of your Mac.

  • Listing objects and their instance names (of closed source SWF)

    I have an API for a flash player that I want to use, but it is closed source. I know I could try a decompiler but I need to see what it loads and what it's doing at runtime.
    I'd like to see the objects (and all their info) that it loads and has on stage along with thier instance names. I'd like to see what this SWF has/does so I can write my AS3 code accordingly... maybe add some additional event listeners.
    Is there any was to go about doing this? I know there's some AS3 commands to get this information but I dont know what they are. If you all could give me some hints at which commands would be useful that would be great.

    "I need to see what it loads"
    You can use Fiddles, Charles or Firebug to monitor traffic (what it loads).
    As for the rest of your question - good luck. Although it is possible to decompile swf of course, reverse engineering is an extremely complex time consuming task. In the majority of cases it is easier and faster to replicate functionality from scratch than to try to understand SWF's logic.
    Unless you know packages structure - there is no native way to figure out/access application domain.

  • Tween and getting instance names problems

    Hi, iv got these buttons animated using the inbuilt tween
    function and am coding them like this:
    function navOver(e:MouseEvent):void {
    var page = MovieClip(e.currentTarget).buttonThumb;
    var myTween16:Tween = new Tween(page, "y", Regular.easeOut,
    0, -25, 0.35, true);
    function navOut(e:MouseEvent):void {
    var page = MovieClip(e.currentTarget).buttonThumb;
    var myTween17:Tween = new Tween(page, "y", Regular.easeOut,
    -25, 0, 0.35, true);
    function navClick(e:MouseEvent):void {
    var page = MovieClip(e.currentTarget).buttonThumb;
    page.y = 0;
    button.addEventListener(MouseEvent.ROLL_OVER, navOver);
    button.addEventListener(MouseEvent.ROLL_OUT, navOut);
    button.addEventListener(MouseEvent.MOUSE_DOWN, navClick);
    but if i click on the button before the animation has
    finished it ignores the
    page.y = 0; code and does nothing. how can i fix this?
    also im trying to get the instance name of a mc called
    "home" using this code:
    MovieClip(e.currentTarget) wich gives me the result
    [object button_1]
    and
    MovieClip(e.currentTarget).instanceName returns
    undefined
    neather of which are the instance name.
    i cant hardcode the function because its used on lots of
    different mcs throughtout the flash file
    thanks

    if you want to send the 'page' back to the 0 position, you
    might be better off declaring the tweens outside the method, in
    this way you can control them in 'other' methods that aren't local
    to where the assignment is made, for instance:
    var myTween17:Tween;
    then in the handler navOut, just 'assign' the tween:
    myTween17 = new Tween( .. );
    then in the navClick method you could call:
    myTween17.stop();
    myTween17.rewind();
    and that should reset the clips position to 0
    for your other question use:
    MovieClip(e.currentTarget.name);

  • How to get Host name and SQL Instance Name by T-SQL

    I am using SQL 2000, 2005 and 2008. I have few multi instances SQL servers. I would like to gather following information:
    Host Name
    SQL Instance Name
    SQL Version
    Server1
    Server1
    SQL 2000
    Server1
    Server1\ABC
    SQL 2005
    Server1
    Server1\XYZ
    SQL 2008
    Server2
    Server2
    SQL 2008
    Is there any way I can get it by T-SQL? Any help would be appreciated.
    Thanks
    Saumen 

    SELECT
    SERVERPROPERTY('MachineName') AS [ServerName],
    SERVERPROPERTY('ServerName') AS [ServerInstanceName],
    SERVERPROPERTY('InstanceName') AS [Instance],
    SERVERPROPERTY('Edition') AS [Edition],
    SERVERPROPERTY('ProductVersion') AS [ProductVersion],
    Left(@@Version, Charindex('-', @@version) - 2) As VersionName
     |
    Blog: MSBICOE.com |
    MCITP - BI, SQL Developer & DBA
    Hate to mislead others, if I'm wrong slap me. Thanks!

  • Using and storing instance names

    I know you can store instance names in an array and call on the array values to reference the instance names in it.
    I was wondering if there is any way I can take an instance name, feed it directly into a function and use the name of the function variable/array/whatever to affect the object instance of whatever I name.
    if it's an array of instance names, what is it actually an array of?
    Also, is there any way to hold and reference an instance name in a single value?
    sidenote:
    this doesnt have much to do with my question, but can arrays be fed directly into the header of a function?

    Look, there is no any ambiguity in what array holds - it is what you make it hold.
    If you are talking about instance names as strings, the following can be done (given objects with instance names are instantiated);
    var myInstanses:Array = ["instance1", "anotherInstance", "myMovie"];
    than you can feed instance name onto a function and do whatever you need to:
    function myFunction(instanceName:String):void{
         this[instanceName].x = 200;
    myFunction(myInstances[1]);
    But if you are talking about instances as instances - not names:
    var myInstanses:Array = [instance1, anotherInstance, myMovie];
    function myFunction(instance:Sprite):void{
         instance.x = 200;
    myFunction(myInstances[1]);

  • OSEHQ is compressed (notebook won't load windows and gives this error message)

    Hi there, 
    my noetbook wont start windows, and gives this message when i turn it on-  
    OSEHQ is compressed
    Press ctrl+alt+del to restart
    The last thing I remember doing was compressing my C drive to save some disk space.
    please HELP! 

    Yep, compressing the hdd can cause all sorts of problems.
    http://www.vistax64.com/tutorials/202609-bootmgr-compressed-message-boot-fix.html
    ******Clicking the Thumbs-Up button is a way to say -Thanks!.******
    **Click Accept as Solution on a Reply that solves your issue to help others**

  • Transporting DBConnect DataSource to BWQ / BWP and Oracle Instance Name

    Hi,
    I have a DBConnect Datasource / Source System in our BWD system that is pointing to an Oracle instance that is also a DEV system.  When we go to BWQ / BWP we want the source system to point to the Oracle QA / PRD system.  Is there a table where a mapping can be maintained pointing the DB Connect source system to different Oracle instances based upon the BW system that it is in?
    Thx, MGW

    Mel,
    Create the respective dbconnect source system in BWQ and BWP. After the creation, maintain table RSLOGSYSMAP. To maintain table, go to rsa1, menu --> Tools --> Conversion of Logical System Names, and maintain the source system and target system values.
    -Saket

  • Click on the iTunes Store it only loads half way and gives a blank screen...

    My internet connection is fine, and when I open up iTunes everything comes up right, my iPod works perfectly. But when I click on the iTunes Store it only loads halfway and gives me a blank screen. HELP!

    There are at least 20 threads pertaining to this problem (some from last year, one I saw was from 2006). I suggest anyone who visits this thread redirect to https://discussions.apple.com/thread/3223139?start=0&tstart=0. It has the two most popular solutions and anyone with ongoing issues can discuss and/or form an unruly mob there.

  • Flash CS5 instance name problems

    I can't give instance names in my AS2 project. When I click on the Instance Name box it is locked. I can only give instance names to the text objects. Movie clips and buttons are locekd. Please Help

    Hey guys,
    I struggled with this too.
    It seems if you make a reference to it in the action script it allows you to set an instance of that name (basically. why would you need to set a name if there is no reference to it in the action script)
    e.g add something like
    mc_myMovieClipName.addEventListener(MouseEvent.MOUSE_OVER, myFunction);
    and you will be allowed to rename a new symbol of that name.
    (or change your existing references to your OLD movieclip name and you will be allowed to rename it)
    If there are 2 symbols on the stage and only 1 reference in the code. only 1 symbol will be allowed to be named and you will have to add...
    mc_myMovieClipName2.addEventListener(MouseEvent.MOUSE_OVER, myFunction2);
    to the code in order to name the second movieclip.
    Please let me know if this helps.

  • Change DB name/ instance name during an UPGRADE ?

    Is it possible to change the database name and the instance name during an UPGRADE (from 9i to 10g for instance) ? If is possible, how ?
    Thanks,
    D.

    Two Options:
    1. Change the name in 9i, then Upgrade to 10g
    2. Upgrade to 10g, then change the name in 10g
    There is no automatic way to do it during upgrade.

  • VideoPlayer, FMS, and application instances

    I am trying to playback recorded streams from a Flash Media Interactive Server using the VideoPlayer component in Flex  4/Flash Builder 4.
    If the stream is located in the <serverpath>/streams/vod/_definst_ directory then I can get to it by setting the 'source' parameter of the VideoPlayer to "<server>/vod/streamname" assuming streamname is an .flv file.  If the stream is located in an application directory (e.g. 'app1') in the _definst_ directory (i.e. <serverpath>/app1/streams/_definst_), then I can successfully play it back by setting the 'source' parameter to "<server>/app1/streamname".
    What I can't get to work is when I have a stream recorded to an instance within an application directory.  So if the application is "app1' and the instance name is "inst1" it would be literally located in <serverpath>/app1/streams/inst1 directory.  Setting the source parameter to this "<server>/app1/inst1/streamname" does not work.  It seams to be ignoring the 'inst1' part of the path because the server side log shows '_definst_' as the instance name being run.
    I know this is in part a Flash Media Server question, but manually writing a video player works.  I would just like to get the Flex 4 VideoPlayer component to play the video.
    Thanks for any help.

    I have the same problem, but it seems that Adobe simply ignores the existence of it.

  • Linkage identifier versus instance name

    What are the differences between linkage identifier and
    instance name of any
    object(mc,symbol etc)
    Some commands in flash require linkage identifiers to me
    provided.What if
    the movieclip is being created dynamucally.How would then the
    link Id be
    given.
    On the other hand if movieclip is static with linkage
    identifier then how to
    create handlers (on press ,etc) for it after attcahig it on
    stage or some
    container to recieve events from those container also.
    Any suggestions and thoghts appreciated.

    the instance name is a string used to reference an
    instantiated (or on-stage - though it can be off-stage) object.
    a linkage id is a string that's used to reference a library
    symbol. it can only be created by right clicking on a library
    symbol and clicking linkage (or properties).
    therefore, a dynamically created movieclip cannot have a
    linkage id assigned.
    one the other hand a movieclip created using a linkage id
    (ie, by using attachMovie() ) is require to have an instance name
    supplied (as the first attachMovie() parameter) and that instance
    name (or a reference to the attachMovie() statement) is used to
    reference the new movieclip (and assign handlers, properties and
    other methods).

  • Since trying to update yesterday, my computer won't download any updates and itunes 11.1 says "Internal Error" and gives me the following info when I click on a song or podcast: Exception Name: NSInvalidArgumentException Description: -[_NSConcreteUserNoti

    Since trying to update yesterday, my computer won't download any updates and itunes 11.1 says "Internal Error" and gives me the following info when I click on a song or podcast:
    Exception Name: NSInvalidArgumentException
    Description: -[_NSConcreteUserNotification activationType]: unrecognized selector sent to instance 0x25a06b0
    User Info: (null)
    0   CoreFoundation                      0x922216fb __raiseError + 219
    1   libobjc.A.dylib                     0x920108db objc_exception_throw + 230
    2   CoreFoundation                      0x9222563d -[NSObject(NSObject) doesNotRecognizeSelector:] + 253
    3   CoreFoundation                      0x9216af77 ___forwarding___ + 487
    4   CoreFoundation                      0x9216ad22 _CF_forwarding_prep_0 + 50
    5   iTunes                              0x00df38e2 iTunes + 14624994
    6   iTunes                              0x00df36ae iTunes + 14624430
    7   libobjc.A.dylib                     0x9201c6c5 -[NSObject performSelector:withObject:withObject:] + 77
    8   Foundation                          0x93c12d85 -[_NSConcreteUserNotificationCenter _sendDelegateMessage:sendToAppDelegate:withNotificationFromMessage:] + 335
    9   Foundation                          0x93c12eaf -[_NSConcreteUserNotificationCenter _notificationPresentedMessage:] + 58
    10  Foundation                          0x93c137c2 __block_global_1 + 156
    11  libdispatch.dylib                   0x9371b2cf _dispatch_call_block_and_release + 15
    12  libdispatch.dylib                   0x9371ea80 _dispatch_client_callout + 46
    13  libdispatch.dylib                   0x9371c8e8 _dispatch_main_queue_callback_4CF + 223
    14  CoreFoundation                      0x9211b255 __CFRunLoopRun + 1829
    15  CoreFoundation                      0x9211a7c4 CFRunLoopRunSpecific + 308
    16  CoreFoundation                      0x9211a67b CFRunLoopRunInMode + 123
    17  HIToolbox                           0x90b6fc76 RunCurrentEventLoopInMode + 242
    18  HIToolbox                           0x90b76eb9 ReceiveNextEventCommon + 374
    19  HIToolbox                           0x90b76d34 BlockUntilNextEventMatchingListInMode + 88
    20  AppKit                              0x97621923 _DPSNextEvent + 709
    21  AppKit                              0x97621167 -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] + 119
    22  AppKit                              0x9761d78c -[NSApplication run] + 855
    23  iTunes                              0x0017a898 iTunes + 1546392
    24  iTunes                              0x0017a709 iTunes + 1545993
    25  ???                                 0x00000002 0x0 + 2

    Please read this whole message before doing anything.
    This procedure is a test, not a solution. Don’t be disappointed when you find that nothing has changed after you complete it.
    Step 1
    The purpose of this step is to determine whether the problem is localized to your user account.
    Enable guest logins* and log in as Guest. Don't use the Safari-only “Guest User” login created by “Find My Mac.”
    While logged in as Guest, you won’t have access to any of your personal files or settings. Applications will behave as if you were running them for the first time. Don’t be alarmed by this; it’s normal. If you need any passwords or other personal data in order to complete the test, memorize, print, or write them down before you begin.
    Test while logged in as Guest. Same problem?
    After testing, log out of the guest account and, in your own account, disable it if you wish. Any files you created in the guest account will be deleted automatically when you log out of it.
    *Note: If you’ve activated “Find My Mac” or FileVault, then you can’t enable the Guest account. The “Guest User” login created by “Find My Mac” is not the same. Create a new account in which to test, and delete it, including its home folder, after testing.
    Step 2
    The purpose of this step is to determine whether the problem is caused by third-party system modifications that load automatically at startup or login, by a peripheral device, or by corruption of certain system caches.
    Disconnect all wired peripherals except those needed for the test, and remove all aftermarket expansion cards. Boot in safe mode and log in to the account with the problem. Note: If FileVault is enabled on some models, or if a firmware password is set, or if the boot volume is a software RAID, you can’t do this. Ask for further instructions.
    Safe mode is much slower to boot and run than normal, and some things won’t work at all, including sound output and Wi-Fi on certain models.  The next normal boot may also be somewhat slow.
    The login screen appears even if you usually log in automatically. You must know your login password in order to log in. If you’ve forgotten the password, you will need to reset it before you begin.
    Test while in safe mode. Same problem?
    After testing, reboot as usual (i.e., not in safe mode) and verify that you still have the problem. Post the results of steps 1 and 2.

  • Reducing a SWF file size / creating "instance names" for website loading time improvement

    Im hoping someone clever can help...
    What i have done so far:
    1) Created a flipbook using indesign CS5.5 that contains approx 25
    images (embedded PNG's), these need to be good quality as this is a
    portfolio - I'd also like to keep the 'page curl' effect. This makes the SWF generated cira 25MB.
    2) created a Flash website "wrapper" to hold the above flipbook and add
    features such as "bookmarks", links to other sites and forward/backward
    page navigation buttions.
    The issue we have is that because the flipbook SWF is 25MB the site
    load time is slow.
    What can be done to speed this up without compromising the image
    quality?
    1) Is there a way to make the indesign SWF smaller?
    2) is there a way in indesign to properly give each page an
    "instance name" so that they can be controlled from flash and therefore
    I can load each pages image as and when needed.
    any other ideas?
    (If you'd like to visit the website to view the loading issue http://www.lizblackdesigns.co.uk)
    Thanks
    Liz

    these need to be good quality as this is a portfolio
    The approach to your portfolio website seems very outdated and will not help you in the near future. Flash is being used less and less with the increase in Mobile Devices being used to access the internet - a large chunk of which include Apple's iDevices which don't support Flash. This alone is a reason not to do it, however there are a few other big issues with the method you have chosen.
    There is no "content" on your website for any search engine to find. No text. No meta data. No image alt tags. No titles. Nothing. In other words, your website will not be found by the people you are trying to attract. I would imagine for a portfolio site, you may want to re-think this approach.
    The way the Flash file was created is the worst possible way to add Flash to the web as you have only embedded image files - and this is your entire site?! You could have included some text, which would have been viewable by search engines, and used color shapes to increase quality but lower filesize.
    The filesize meant it took me over 1 minute to get off your home page. The average internet user will leave your site if you do not keep them interested after 5 seconds. In other words, you should have content of interest viewable within 5 seconds of load time.
    If you are set on keeping the Flash setup for your website, re-build using as much text, color shapes and lines as you can (vector work in other words) and do not rasterize/export as image. This will drastically reduce load time and increase quality. You will also want to divide your file into sections and create more than 1 HTML page so that the browser only loads a bit at a time. You might also want to set a maximum size container for the Flash file as on my browser, it looks extremely pixelated and is very large, but unclear.
    I would suggest looking into HTML5 if you are keen to create a website that can be viewed by around 98% of the web surfing people and it will also mean you can use an image slider (or similar) to show good quality images of your work. This will aid your site in being found by search engines but will also allow you to update sections of the site without re-publishing the entire Flash file.
    Rik

Maybe you are looking for