Problem with the instruction FOR... Once again!

Hello world

Well, I'm still doing a slideshow of car using external files and can't see the end. The current movie is here:

http://www.virtuallglab.com/projects.html

I also enclose the code. My problem is I had initially set up an animation with 2 pictures slide with text and then wait 4 seconds before slipping outside, and then next photos and text would slip in and so on, using a setInterval.
The problem is the loop FOR seems to ignore the setInterval and slides of the 'wait' service, so buckle up just quickly and get to the last picture, so now the example above, it comes the last picture (I = 9) and that's it!

Can you do not include another function in a statement FOR. Or is there a way to tell the loop TO wait for all movement is complete?

Any help greatly appreciated

***************************************************

Mx.transitions import. *;
Import mx.transitions.easing. *;


for (i = 0; i < 10; i ++) {}

var picLeft = "photos /"+ i + ".jpg"; ".
var picRight = "pics /"+ i +"b.jpg";
var txtToLoad = "text /"+ i + ".txt"; ".

this.createEmptyMovieClip("leftHolder",1);
leftHolder.loadMovie (picLeft, i, leftHolder.getNextHighestDepth ());
leftHolder._x = - 200;
leftHolder._y = 15;

var leftTween:Tween = new Tween (leftHolder, "_x", Strong.easeOut, leftHolder._x, 10, 2, true);

this.createEmptyMovieClip("centerHolder",2);
centerHolder.loadMovie (picRight, i + "b", centerHolder.getNextHighestDepth ());
centerHolder._x = 180;
centerHolder._y = 250;

var centerTween:Tween = new Tween (centerHolder, "FLF", Strong.easeOut, centerHolder._y, 15, 2, true ");

Text._x = 600;

myData = new LoadVars();
myData.onLoad = function() {}
text.carText.text = this.content;
};
myData.load (txtToLoad);

var textTween:Tween = new Tween (text, "_x", Strong.easeOut, text._x, 420, 2, true);

myInterval is setInterval (wait, 4000);.



function wait() {}
var leftTweenFinished:Tween = new Tween (leftHolder, "_x", Strong.easeOut, leftHolder._x,-200, 1, true);
var centerTween:Tween = new Tween (centerHolder, "FLF", Strong.easeOut, centerHolder._y, 250, 1, true ");
var textTween2:Tween = new Tween (text, "_x", Strong.easeOut, text._x, 600, 1, true);
clearInterval (myInterval);

}
}


***************************************************************************************** ***

There is no way to tell a loop to wait for. This isn't what they are doing.

All of the loop for runs (if possible and it is not a kind of infinite loop) completely before whenever the image is rendered.

If you want to spread in time, you must use the setInterval - but not inside a loop for! If you do this, you immediately set, but the number of intervals of your loop. In this case you will also assign IDS for these intervals to the same variable, replacement effectively the value so you won't ever be able to erase most of these intervals.

That means rethink you the entire structure. Set up a kind of counter and limit like this:

var slidesToShow:Number = 10;
var curSlide:Number = 0;

Then have your setInterval the curSlide increment each time it is called, and check to see if it showed all the. This is where the "loop".

As for the other part of your question - Yes you are actually two different issues in progress - once again, you can't do a loop for, wait for anything. So no there is no way to pause while you wait for your pre-teen at the end. But you can be notified when a Tween completes.

See the documentation on the tween class in the help files. You will find the onMotionFinished event. If you configure one of those to begin with everything that needs to be started when the Tween is finished.

You should also use the MovieClipLoader class to load your images, because you don't know how long it will take to load. Using this class, you get a nice event (onLoadInit) that tells you when the asset is ready for use.

Finally, I think that you might want to use instead of setInterval setTimeout. It runs only once, whereas setInterval repeat forever. So I think that your algorithm would be something like that.

1. load creditrice
2. when ready to animate in and set onMotionFinished Manager
3. when the query is finished start loading assets and setTimeout for 4 seconds.
4. when 4 seconds is up or the clip is loaded (no matter what either takes longer) go to 2 and repeat.

If this is going to be run locally on a hard drive or CD you will have no problem with the length of time that it takes to load external assets, but if it's on the web it's going to take time.

Tags: Adobe Animate

Similar Questions

  • Cannot install Vista service pack 2 is 800f0a09 error code with the message that there are problems with the driver for dell latitude

    Original title: why I get error code 800f0a09 to upgrade to windows vista service pack 2

    I have a laptop del that is running on Windows Vista Edition Home Premium. I tried to download itunes but it requires service pack 2. Whenever I try to update to service pack 2, I get the message following error code 800F0A09. He also mentioned problems with the driver for dell latitude. What can I do to fix this please.

    Thank you

    Hello

    Please join Microsoft Community where you can find the necessary information on Microsoft products!

    You can not install Vista Service pack 2 and get the error with code 800f0a09 and the message that there are problems with the driver for dell latitude.

    The problem may occur if some of the components of the update are corrupt.

    What is the full error message that you receive?

    I suggest you follow the steps mentioned below to check if the problem is with the update components:

    Method 1: Reset the update components

    See the site:

    How to reset the Windows Update components?

    http://support.Microsoft.com/kb/971058

    Warning: This section, method, or task contains steps that tell you how to modify the registry. However, serious problems can occur if you modify the registry incorrectly. Therefore, make sure that you proceed with caution. For added protection, back up the registry before you edit it. Then you can restore the registry if a problem occurs. For more information about how to back up and restore the registry, click on the number below to view the article in the Microsoft Knowledge Base:

    http://Windows.Microsoft.com/en-us/Windows-Vista/back-up-the-registry

    Method 2: Run the system update readiness tool

     

    See the site:

    System update scan tool corrects errors of Windows Update in Windows 8, Windows 7, Windows Vista, Windows Server 2008 R2 and Windows Server 2008

    http://support.Microsoft.com/kb/947821

    Method 3: Turn off the antivirus software

     

    See the site:

    Disable the anti-virus software

    http://Windows.Microsoft.com/en-in/Windows-Vista/disable-antivirus-software

    Important note: Antivirus software can help protect your computer against viruses and other security threats. In most cases, you should not disable your antivirus software. If you need to disable temporarily to install other software, you must reactivate as soon as you are finished. If you are connected to the Internet or a network, while your antivirus software is disabled, your computer is vulnerable to attacks.

    I hope this helps. If the problem persists, let know us and we would be happy to help you.

  • my pc will not connect to wireless internet... It is said there could be a problem with the driver for the wireless network connection card

    connection network card

    my pc will not connect to wireless internet... It is said there could be a problem with the driver for the wireless network connection card... I'm not sure how to solve the problem of the dat

    Hello

    Did you change your computer?

    I suggest you to follow the links and check out them.

    The problems of Internet connection

    http://Windows.Microsoft.com/en-us/Windows-Vista/troubleshoot-Internet-connection-problems

    Solve problems, find wireless networks

    http://Windows.Microsoft.com/en-us/Windows-Vista/troubleshoot-problems-finding-wireless-networks

    Windows wireless and wired network connection problems

    http://Windows.Microsoft.com/en-us/Windows/help/wired-and-wireless-network-connection-problems-in-Windows

    Tips for solving common driver problems

    http://Windows.Microsoft.com/en-us/Windows-Vista/tips-for-fixing-common-driver-problems

  • Failed to perform recovery of factory setting - error 0x8007045D Code / product key error - "ERROR!" We encountered a problem with the request for approval.

    Original title: product key error

    Hi all...

    I have ' tried to download the disc Image of Windows 7 (ISO file), but when I insert my product key, the system cannot check it.
    I use the laptop Sony Vaio VPC EG35EG with preinstalled Windows 7 Home Basic 64 bit inside.
    Now, after that there is error (I cannot yet perform plant pose recovery; always finished with error 0x8007045D Code), I need to install clean my laptop with the USB or DVD Installer key. But then, when I try to download it, my product key (I found it on the sticker at the bottom of the laptop) are not validated by microsoft. It is said:

    "ERROR!" We encountered a problem with the request for approval.

    What should I do now? Y does it can someone help me?
    Thank you.

    Consider the following text:

    How to: What are my options for Windows 7 reinstall media?

    Make sure you scroll down and read the section:

    What to do if you cannot get your manufacturer recovery media, refuse to use or to buy it or the Microsoft Software Recovery Website does not work?

    also check:

    https://techingiteasy.WordPress.com/2012/04/13/how-to-activate-Windows-7-OEM-license-using-a-retail-disc/

  • Video device USB has a driver problem__ __There is a problem with the driver for USB video Device.__Device information __Name: __ID USB video device: USB\VID_05CA & PID_180C & MI_00\6 & 69C3BD0 & 0 & 0000 code __Error: 10 _ _ _

    I hava a dell inspiron 1440 with windows 7 and a a few days ago, my webcam was working just fine but know that it gives me this after troubleshooting

    Has a USB video device driver problem
    Not fixed
    There is a problem with the driver for USB video device. The driver must be reinstalled.
    The device information
    Name: USB video device
    ID: USB\VID_05CA & PID_180C & MI_00\6 & 69C3BD0 & 0 & 0000
    Error code: 10

    Hey laloo.16,

    As the error message states clearly that reinstalling the driver is required, please do the same. You can uninstall the driver that is currently installed from the Device Manager.
    To access Device Manager:
    1. go to start and type Device Manager.
    2. Select Device Manager in the control panel list.
    3. go to your device.
    4. to remove:
    Right-click on it and select Properties.
    5. Select the driver tab and click on uninstall to uninstall the existing driver.
    6. close Device Manager.
    Now go to the link below. Download the Dell WebCam software for your product.

    http://support.Dell.com/support/downloads/DriversList.aspx?OS=W732&CATID=-1&DateID=-1&impid=-1&OSL=en&typeid=-1&FormatID=-1&SERVICETAG=&SystemID=INSPIRON1440&hidos=WLH&hidlang=en&TabIndex =

    Please choose the appropriate version of Windows 7.  Install the driver and see if that brings your webcam to work.

    Kind regards

    Shinmila H - Microsoft Support

    Visit our Microsoft answers feedback Forum and let us know what you think.

  • There is a problem with the driver for a wireless adapter that if it is not compatible or not supported

    My grandmother came to visit me in Belgium and brought her laptop with her. It is Windows 7 and I bought in Ukraine. Thus, she cannot use wireless internet at my place. Troubleshooting scan says there is a problem with the driver for a wireless adapter that is it is not compatible or not supported, something like that. All sound systems are in Russian is not easy for me to explain it. Is it possible to fix this problem or she can't use her laptop to go on the net at all? Thank you!

    If it's a driver fault, can go you on another pc to work to manufacturers support web site for the 'Ukraine' pc and see if the wireless drivers are available there. If they are, download the latest compatible drivers for your pc and transfer them to it by a stick of memory from SD or USB and then install them.

    This may be due to a setting of your network security wireless, for example, that is your network is set to WPA2 but pc does not support. Check configurations for compatibility with your router wireless sound.

    See if anything here help - http://windows.microsoft.com/en-us/windows/setting-wireless-network#1TC=windows-7

    At worst, is it not possible to connect via a cable to your router, esp, if is only a visit to sound.

  • There is a problem with the driver for Canon PowerShot SD1200 IS. The driver must be reinstalled.

    There is a problem with the driver for Canon PowerShot SD1200 IS. The pilot
    must be reinstalled.

    Gerald

    To allow us to help you better, please provide as much detail as possible about the problem you are experiencing.


    If you design your question effectively, you can get good information from people who are familiar with the subject and who are happy to help you.

    Prepare your question. He thinks through. Hasty-survey questions get hasty responses, or none at all.

    What diagnosis have so far

    An effective question you will get help read faster how here
    Suggestions for asking for help on a site.
    http://www.CatB.org/~ESR/FAQs/smart-questions.html

    BTW, I see you have cross posted this on Technet

    http://social.technet.Microsoft.com/forums/Windows/en-us/a1bd86f2-6914-4cda-9e34-1e3abb75a33c/Canon-PowerShot-SD1200-is?Forum=tnfeedback

  • Windows 8 "There is a problem with the driver for bluetooth hands-free audio"

    There is an X symbol by the sound icon, when clicked, it shows "There is a problem with the driver for the audio blue tooth hands-free". Troubleshooting has not been set, said that there is a bluetooth hands-free audio driver problem. In addition, when you look at the audio in Device Manager, error code 19 lights during all the points listed under ' audio, video and game controllers ".

    Hello

    Thanks for posting your question on the Microsoft community.

    We need more information about the issue so that we can help you better.

    What is the brand and model of your computer?

    Thank you for details on the question and your efforts to resolve.

    This problem may occur because of corrupted audio driver or settings.

    I suggest you run this Microsoft fixit and verify.
    Reference:
    Hardware devices do not work or are not detected in Windows
    https://support.Microsoft.com/en-us/mats/hardware_device_problems

    Automatically, he diagnoses and fixes problems with the hardware. Keyboard and mouse are not detected by the Manager of devices or when they do not work.

    I would also say that you uninstall and reinstall the sound drivers under "Audio, video and game controllers" and check.

    To uninstall the driver, please follow these steps:

    a. press Windows + R keys, type devmgmt.msc in the run window and press ENTER.

    b. Click to enlarge "Audio, video and game controllers", right click on the device, and then click Uninstall.

    c. restart the computer.

    Now, reinstall the drivers from the computer manufacturer's website and check the.
    Reference:
    http://Windows.Microsoft.com/en-us/Windows-8/all-drivers

    I hope this information helps.

    Please let us know if you need more help.

    Thank you

  • There is a problem with the driver for TSSTcorp DVD +-RW Drive SN - 208BB. The driver must be reinstalled.

    Hello
    With the help of the window - 8 installed on newly purchased Dell Inspiron notebook
    For a few days, I wasn't able to use my CD DVD drive because there is a driver problem, here's the trouble shoot report
    could someone help me how this issue be resolved
    TSSTcorp DVD +-RW Drive SN - 208BB has a driver problem fixed is not fixed
     
    There is a problem with the driver for TSSTcorp DVD +-RW Drive SN - 208BB. The driver must be reinstalled.
    Information InformationalDevice
    Name: TSSTcorp DVD +-RW Drive SN-208BB
    ID: SCSI\CDROM & VEN_TSSTCORP & PROD_DVD +-RW_SN-208BB\4 & BB94CF & 0 & 040000
    Error code: 19
     
    Reinstall the complete device driver
     
    There is a problem with the driver for TSSTcorp DVD +-RW Drive SN - 208BB. Reinstall the driver may resolve this issue.
     

    You can check the following registry key? :

    HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Class\ {4D36E965-E325-11CE-BFC1-08002BE10318}

    To the registry for this key, in the right window, in the world is here, under 'Name', a LowerFilters and UpperFilters value?

    If so, for UpperFilters and LowerFilters, value which is listed under "data"?

  • There is a problem with the driver for Ralink Bluetooth PCIe Adapter. The driver must be reinstalled error code 39.

    HP Pavilion 17 laptop

    There is a problem with the driver for Ralink Bluetooth PCIe Adapter. The driver must be reinstalled.

    OT: Driver help

    Name: PCIe Ralink Bluetooth adapter
    Error code: 39

    Hello

    Thanks for posting the query on the Microsoft Community Forums. You have reached the right place. Let us work together to find the cause of this problem and try to solve.

    What is the number of full model of the laptop?

    39 error code means Windows cannot load the driver for this hardware device. The driver may be corrupted or missing. To resolve the problem, you will need to uninstall and reinstall the drivers for Ralink Bluetooth PCIe card on the manufacturer's Web site.

    I hope this helps. Let us know if you have other problems with Windows in the future.

  • Hello! I have a problem with the Simulator for android is not work. What is the reason?

    Hello! I have a problem with the Simulator for android is not work. What is the reason?

    Depending on your mobilde device you must first unlock the developer settings in order to test the AIR apps on it.

    Where to find these settings depends on your specific device.

  • Problem with the organizer for first elements ver 9.0

    For some reason, I can't enter the organizer for my Adobe Premiere Elements 9.0 worm.  I get the error says "the organizer has stopped working", windows can check online for a solution to the problem, or it tells me to close the program.  When I check the details of eyesight problems, I get a list.  Here are some quotes: problem event name: APPCRASH application name: PhotoshopOrganizerElements.exe

    Timestart application: 4ca3a3b5 which I do not know what everything means.  Should I reinstall Adobe elements again?   Anya

    I got elements of Prime Minister for about 6 months now and have not had a problem with the Organizer until last week.

    What I have to reinstall the whole program or I should just install the portion of the organizer of the program?

    Anya

    Thank you for responding.

  • problem with the drivers for the card microsoft virtual wifi miniport... problems with PnP devices

    He said to reinstall the drivers for this problem, but they don't reinstall... also he says hardware changes have been detected... can someone explain in easy to understand words what the problem is and how to fix it... pleaseeeeee... Thank you... The convenience store said: THERE IS A PROBLEM WITH THE DRIVER of MICROSOFT VIRTUAL WIFI MINIPORT ADAPTER... DRIVERS MUST BE REINSTALLED... it won't reinstall... also: PROBLEM WITH PnP DEVICES HARDWARE CHANGES HAVE BEEN DETECTED? CAN SOMEONE HELP ME UNDERSTAND, IN EASY WORDS, EXACTLY WHAT I NEED TO DO TO FIX THIS... CD-ROM... IM USING A SAMSUNG LAPTOP MODEL NPR 519 RUNNING WINDOWS 7... Thank you... Update on the microsoft Web site says: this DEVICE no IS NOT WORKING PROPERLY BECAUSE WINDOWS cannot LOAD THE DRIVERS REQUIRED for THIS DEVICE (code 31)... im not computer savvy please someone help

    Hi MAGIC,

    It seems that you may need to update your BIOS firmware.

    You may need to contact Samsung for more information, if the update is available for download on their Web site.

    When started this issue is happening?

    You can disable the virtual WiFi adapter, as it essentially works as a tool of development at the moment:

    http://msdn.Microsoft.com/en-us/library/dd815243%28VS.85%29.aspx

    What is the device that has the problem?

    Reinstall the drivers to fix the problem?

    Chris
    Microsoft Answers Support Engineer
    Visit our Microsoft answers feedback Forum and let us know what you think.

  • I now have a problem with the update for Windows Live Essentials 2011

    I don't understand how it happened, but maybe someone could enlighten me?

    First of all, I was informed of an update for Microsoft Security Essentials. So of course, I did the update because I didn't want to be protected.

    I don't know if this is related somehow. I think that my update understood also as a Windows Live Essentials package. When I checked my e-mail and instant messaging, I noticed that the format has changed, and now, I think it's the new WLM 2011.

    It may seem very nice and put up-to-date, but it caused a series of serious problems for me. Let me explain:

    First of all, I must clarify that I am disabled and use the speech recognition, Windows speech recognition Dragon NaturallySpeaking both, because I can't use my hands.

    In the original WLM before the update, if I were using Dragon NaturallySpeaking, I was able to dictate with great ease and had no problem. If I wanted to then send the email I would say just 'send' and e-mail would go. With WLM 2011, if I say that now, it does not work.

    It's just a problem that I have. The next problem is much larger. In some cases, Dragon NaturallySpeaking speech recognition will not work and I can't dictate anything. I then have to close WLM completely and then open it again. Then only, it'll work. This happens many times and it's very frustrating, as you can imagine for someone like me.

    Forgive me for saying, it may seem very well with all the new bells and whistles there, but it makes my life a misery at the moment. In my view, there are a lot of bugs that need to be sorted out first with her.

    My question is, can I go back to the original WLM somehow until the update meets my needs? Can I go back to the status quo when WLM 2010 worked well with speech recognition for me?

    If so, can someone tell me how to do what you please?

    If not, then how am I supposed to use these features now?

    Thank you

    HB

    You will find support for Windows Live Messenger in these Windows Live help forums: http://windowslivehelp.com/forums.aspx?productid=2 ~ Robear Dyer (PA Bear) ~ MS MVP (that is to say, mail, security, Windows & Update Services) since 2002 ~ WARNING: MS MVPs represent or work for Microsoft

  • Problem with the driver for the monitor (HP Mini)

    Hey, I'm new here, I searched this forum, but I have found a solution to my problem.

    HP Mini 210-3000 sv, I bought about half a year ago and because my Windows is in Greek and I did not understand a Word, I have re-installed Windows. I am currently with Home Premium 32-bit, if it's important. My problem is that in the monitor drivers that I don't have another generic PnP monitor, but it makes my computer slow and uses a lot of memory RAM and I remember that before reinstall, there was another monitor driver, but I don't remember the name, and now I can't find - or in HP support (it is said that my model does not yet exist) , or an internet forum... I installed the latest graphics drivers from HP (Intel Graphics Media Accelerator 3150, the newest) site, but I'm really confused because there is no place I can find tells me which driver is good for my monitor and I have big problems. Sometimes Windows says I have problems with graphics, that close and reopen again. Can someone help me, please?

    Thank you!

    Download and install the latest chipset driver Intel here.

    Restart the system.

    Uninstall the Intel graphics driver (if it has been installed).

    Resources:
    Uninstall software in Windows 7

    Uninstall or change a program in Windows 7

    Download and install the latest driver HP Intel graphics from here.

    Restart the system and check the result.

Maybe you are looking for

  • switcher app works is not in the ios 9

    I have an iphone running ios 9.3.2 and noticed 6s recently screen switcher app has all the icons (when I take to the left and right) so I need to double-click the home button to view open applications. Can someone help me understand how to solve this

  • Amtrak Train map tracking: not allowed to use Google Maps Client ID

    Amtrak introduced a card to follow up on their Web site at http://www.amtrak.com/train-routes. To access this feature by clicking on the "Get followed now > > >" link (Javascript required), a Google with Amtrak routes map begins to display, and then

  • wanting to know how I can keep my Internet connected until I decided to unplug it

    Hi, I'm wanting to know how I can keep my Internet connected until I had to unplug it. If I leave my computor minutes say 1/2 hour or if the internet wireless connection disconnects and I always have to appear to repair the connection and it says rep

  • 80070490 and error codes 8E5E0147

    When I try to update windows, it will fail.  I get codes of error, as shown in the title.  I've been troubleshooting with microsoft unsuccessfully fix.  I use 32-bit Vista sp2.  If someone could help I would be extremely grateful. I think that this p

  • 10 Windows cannot detect the Nvidia GPU, I'm lost...

    So here's the deal; After weeks "Please install w10" spam I finally gave a w10 installed on my Alienware Laptop m17x. After that, my computer has forgotten the Nvidia card installed, and no matter what I tried it does not detect the GPU. So I used th