IF and ELSE statements

The man... I'm so close to figure this out and I didn't have to go back on the forum for this because I had a few topics here already when I started this project and to halfway through it and now towards the end of it, LOL! I hope that you all don't mind!

in any case...

Now I am trying to get users to fill out 4 boxes with the correct information, then press the ENTER key to go to the next section. Everything works perfectly with this part of my code, however, it is the part on whether they enter the wrong info that I be puzzled over.

I tried the ELSE statements and various forms of listeners and IF statements, but I can't seem to make it work.

When they enter the wrong info, in the entry boxes, I have to be taken to a different image. I had a script in there little worked, but instead of him awaiting until they entered all the information, it would just automatically go to the 'wrong' because technically, they received only a chance to enter the first letter of the first word.

in any case, the code that I use now is attached. It works very well except the part of the erroneous info being entered. If a user has just this framework (where the code is located) and hits ENTER, thn, they are taken as part of 'Wrong', which is good, because technically they do not capture in 4 boxes. But. If they start typing in a box and then press ENTER, they need the same "Incorrect" framework because they have not all enter, but it is not that. Even if they conclude each info box and a letter is missing for example, which is wrong and should go to this 'Wrong' page, but is not.

Any ideas?

It is strange.so your code looks like this (and all the other stuff that was already there?):

If (Key.isDown (Key.ENTER)) {}
trace ("talk to the hand, because I'm no longer listening.");
Key.removeListener (listener);
trace ("the time it was the Enter key, then I should evaluate.");
Evaluate();
}

It should work. I just tested it and it works for me. Well, it worked on the second try, the first time that I misspelled "listner", so be sure that you have spelled everything correctly!

Unless you are sure that it is the function of battery called? How do you know? Y at - he got another code which could be initially move the playback cursor?

BTW, if you use Actionscript, you shouldn't use scenes. There are strange things that occur with it and it is not worth!

Tags: Adobe Animate

Similar Questions

  • If and Else statements? Help!

    I am a dress up game in Adobe Flash 8 (AS2) and I am trying to Show and hide multiple video Clips on the release of a button to sort of a menu like this:


    http://charfade.deviantart.com/art/dress-up-NALA-game-107105062


    Its probably if/else statements, but I do not know how their code in ActionScript 2 , so it could very well help if you had a response

    You can use the movieclips _visible property to show (mc._visible = true) and hide (mc._visible = false) a movieclip mc.

  • How to use an IF ELSE statement and the xdoxslt: get_variable together?

    First of all, I'm a big fan of this forum and I would like to thank the community for helping to make better the world BI Publisher.

    I'm trying to populate a table with a value of years of data with column = PRODUCT and row = month to DATE. Here's the catch, not every month will be given. Then here's where is my problem, I am not able to use an IF ELSE statement with an expression XDOXSLT:GET_VARIABLE so that if there is no given for this month the default value will be 0.

    Can someone help me find a solution to one of the attempts below or a method entirely new? Thank you!

    BP4 = numeric value of months with a DATE (more code to extract only the month DATE not included here)
    JAN1 = PRICE if there is data, 0 otherwise

    (1) I tried and it did not work:
    <? If: xdoxslt:get_variable($_XDOCTX,'BP4'), 01 xdoxslt:set_variable($_XDOCTX,_'JAN1',PRICE) then another end if xdoxslt:set_variable($_XDOCTX,_'JAN1',0)? >
    <? xdoxslt:get_variable($_XDOCTX,'JAN1')? >
    <? end if? >

    (2) I tried and it did not work:
    <? xdoxslt:IfElse (xdoxslt:get_variable($_XDOCTX,'BP4') = '01', xdoxslt:set_variable($_XDOCTX,_'JAN1',PRICE), xdoxslt:set_variable($_XDOCTX,_'JAN1',0))? >
    <? xdoxslt:get_variable($_XDOCTX,'JAN1')? >
    <? end if? >

    (3) I tried and it did not work:
    <? xdofx:If xdoxslt:get_variable($_XDOCTX,'BP4') = '01' xdoxslt:set_variable($_XDOCTX,_'JAN1',PRICE) then another end if xdoxslt:set_variable($_XDOCTX,_'JAN1',0)? >
    <? xdoxslt:get_variable($_XDOCTX,'JAN1')? >
    <? end if? >

    example of XML data:
    < ROW >
    < name > Craig Hernandez < / NAME >
    < DATE > 2013 - 01-01 T 00: 00:00.000 + 08:00 < / DATE >
    < PRICE > 31 < / PRICE >
    BPD of < PRODUCT > < / PRODUCT >
    < / ROW >


    -TRD

    Published by: 990965 on February 28, 2013 08:27

    >
    (1) I tried and it did not work:


    (2) I tried and it did not work:


    (3) I tried and it did not work:


    >
    so

    
    
    

    works for me, it's

  • To what size, we can use if and else in HFM statements rules?

    Hi Experts,

    To what size, we can use if and else in HFM statements rules?
    (Scenario, year, time, account, PKI, value, view, entity, Custom1, Custom3, Custom3, Custom4)

    concerning
    Dev
  • Problem with the checkbox and 'if' statement 'else if '.

    Hi, I had something like this:

    if (this.rawValue=="0" ){
      app.alert("0");
      this.resolveNode("Circle1").presence = "hidden";
      this.resolveNode("cross").presence = "visible";
     }  
    
    
    else if (this.rawValue=="1"){
      app.alert("1");
      this.resolveNode("Circle1").presence = "visible";
      this.resolveNode("cross").presence = "hidden";
      }
    
    else{
      app.alert("2");
       this.resolveNode("Circle1").presence = "hidden";
      this.resolveNode("cross").presence = "hidden";
     }
    

    I put a default position on the neutral State. The values are default: on = 1, off = 0, neutral = 2.

    When I'm clicking my button to check it works only 'market' (1) and (2) State "neutral." 'off' State does not work and I do not know why.

    Please help me with this.

    Hello

    Here is the form to the you: https://acrobat.com/#d=qiBnkcpRnPWxA5hokFXvQw.

    I shook the script, but it wasn't the main problem. The issue was that the box is on the Master Page and had a default value of the neutral. Some objects on the Master Page, as with the values by defect and buttons, checkboxes can behave badly when the form is reparqué (layout: ready event).

    If you take a look at the form, you will see the objects on the design Page behave as expected. However, similar objects on the Master Page by default returns every time that the layout event: loan fires. It has already been noted with Adobe.

    I recommend that you move the objects in a design Page or perhaps use a drop-down list instead of the check box.

    Niall

  • hide and show the icon view using if else statement

    is - it possibleto hide and expose the display icon using if else statement? I try to use erase them but I don't know how show it on again after that I want to come back. Thank you

    There are two functions... EraseIcon and Exposeicon

    Mike

  • If/else statement in the MathScript node

    I want to write if/else statement in MathScript node.

    If (Yes is Yes)

    {

    a = 0;

    }

    other (no = no)

    {

    b = 1;

    }

    'Yes' and 'No'--> of Type String

    'a' and 'b'--> Type Double

    Hi johndoe.

    Thank you for contacting National instruments.

    I would like to highlight a number of items which you may find useful for the implementation of an if-else statement in a MathScript node.  The first is a book white tutorial, which the second part explains how to use LabVIEW MathScript node. The second is an article describing the required syntax to write functions and scripts in the MathScript node, including instructions for the use of the If-Else statements.

    I hope that these help. Please let me know if you need additional assistance.

    Kind regards

    James

  • OATS: script entering does not in the if-else statements

    I created a functional test using Oracle's Web. My database file (.csv) contains a number of numbers that are used to browse through the script with different values. now in my loop for, I have included an if-else with action statements in these (Actions like) by clicking on the different tabs. Now, when I run my script, is to not enter the if-else statement and jumping directly to the next step.

    Here are my script:

    beginStep ("search page", 5)

    {page opening}

    String Var1 = (string) 'value from the .csv data bank ";

    for (int i = 1; i < = 2; i ++)

    {

    beginstep("/ASC",0)

    {

    if(var1=="ABC")

    {

    Task1;

    Task2;

    }

    ElseIf (Var1 == "efg")

    {

    Task1;

    Task2 ;}

    }

    }

    endStep();

    beginStep("/asc",0)

    {

    Task3;

    Task4;

    }

    endStep();

    }

    According to my above script, the script is to jump directly to TAsk3 and 4, instead of going to task if-else performing 1 and 2.

    Thanks in advance.

    Kind regards

    Deepak Khari

    Hello

    Use eval(), c.


    String Var1 = eval ("{{db. Var1.ColumnName}} ")." ToString();

    System.out.println ("scnro_class--->" + Var1);


    Kind regards

    Dembélé M

  • limited number of else statements?

    A change of statements, I so, otherwise if and else. I can add a fourth condition? If so, how?

    Any help would be appreciated!

    You can add as many of "otherwise if"s as you like. "

  • If else statements

    Hello world!

    I cannot re written one "if else" statement of Excel in ActionScript 3. Maybe someone can tell me what am I translated badly in the new formula of AS3.

    The original argument of Excel is:

    =IF(AND(F8<=5,F39>=10),10,IF(AND(F8<=5,F39<10),F39,IF(AND(F8>=6,F8<=10,F39>30),30,IF(AND(F8>=6,F8<=10,F39<=30),F39,IF(AND(F8>10,F39<30),F39,30)))))

    I translated this into AS3 as follows:

    if(q1_preCalc <= 5 && q13_preCalc >= 10)
         {
              q13_preCalc = 10;
         }else if ( q1_preCalc <= 5 && q13_preCalc < 10)
         {
              q13_preCalc = q13_preCalc;
         }else if (q1_preCalc >= 6 && q1_preCalc <= 10 && q13_preCalc > 30)
         {
              q13_preCalc = 30;
         }else if (q1_preCalc >= 6 && q1_preCalc <= 10 && q13_preCalc <= 30)
         {
              q13_preCalc = q13_preCalc;
         }else if (q1_preCalc > 10 && q13_preCalc < 30)
         {
              q13_preCalc = 30;
         }else
         {
              q13_preCalc = 30;
         }

    As you can see, I'm trying to set the vaule of the variable "q13_preCalc" according to the value of 2 other variable: q1_preCalc and q13_preCalc (himself).

    After you set the value, I do the calculation with the value:

    q13_preCalc_2 = (q13_preCalc*0.01)*-2.787;

    I don't know if I translate the "If another 'instructions properly in AS3 since Excel."

    Thank you in advance for your help!

    Rafa.

    It seems correct to me, just the last part is different:

    IF (AND (F8 > 10, F39<>

    but in AS3 you wrote:

    If (q1_preCalc > 10 & q13_preCalc)<>
    {
    q13_preCalc = 30;

    ...

    }

    and I see in your AS3 to 2 variables: q1_preCalc, q13_preCalc

    Where is the 3. ?

    in Excel, you have 3 cells (values): F8, F39 and the cell containing the formula.

  • If an else statement does not

    I'm sure have the conditions and statements typed in wrong. Here is the original code:

    Stop();

    var my_timedReveal:Number = setTimeout (my_delayedReveal, 15000: 1);

    function my_delayedReveal (arg1) {}
    gotoAndPlay ("reveal2");
    }

    cardA .mouse .addListener (mouseDown);
    cardB.Mouse.addListener (mouseDown);
    cardC.Mouse.addListener (mouseDown);

    cardA.onRelease = function() {}
    gotoAndPlay ("reveal1");
    }

    cardB.onRelease = function() {}
    gotoAndPlay ("reveal2");
    }

    cardC.onRelease = function() {}
    gotoAndPlay ("reveal3");
    }

    only now, I want to add an if/else statement so that if none of the mouseDown conditions are met, it will then the variable timeout:

    I have not tried or no this result:

    var my_timedReveal:Number = setTimeout (my_delayedReveal, 15000: 1);

    If (cardA .mouseDown = true) {}
    gotoAndStop ("reveal2")
    }

    else {}
    my_delayedReveal = true;
    }

    What Miss me? Am I even close?

    I have not tried to reason with your code, but when you compare things to equal you use is, not =

    If (cardA .mouseDown == true) {}

    And in the case of a boolean comparison, like that you can just use...

    If {(cardA .mouseDown)

    So see if what you're trying or could have tried to work when you use the comparison properly.

  • PHP if else statement

    If ($_SESSION ["FirstName"] == "") AND ($_SESSION ['name'] == ' ') {}

    AND is not correct... what would I use to have an if else statement that has more then a variable as the fi part?

    If ($_SESSION ["FirstName"] == "" & $_SESSION ['name'] == ' ') {}

  • What is the Dell's Vision and Mission statements

    Hello

    I searched our intranet trying to find the Dell's Mission and Vision statements and cannot locate.  My colleagues not can find them as well.  Where can we find this information?

    It is worded a little differently, but it's the same thing.

    http://www.Dell.com/learn/us/en/uscorp1/purpose-and-values

  • OME does not receive details of the inventory and the State for some devices

    OME does not receive the details of the inventory and the State for some servers.

    For example when looking at one of our PowerEdge R620s is all that presents itself:

    iDRAC firmware and LCC is updated (version 2.21.21.21 is installed.)

    I reset the iDRAC, and that did not help.  I have no problem with most of the other R620s in the same range of discovery.

    I deleted the object to OME and re-discovered twice over the past week it but did not help.

    Things seem ok when I use the troubleshooting tool:

    Anyone has any info on what may be going on here or how to fix this?

    Thank you

    Hello

    Thanks for the details in the post.

    Wanted to check what version of OME use you - OME 2.1?

    If so, this behavior with ws - man discovery could potentially due to expiry of certificate on this device. You can launch the iDRAC user interface and confirm the certificate information.

    2.1 the OME, the WS - Man communication component is updated. The most recent component does not communicate with the device if that device has been exceeded in the certificate.

    Sslresetcfg running via racadm will reset the certificate. For details and solution, see same threadhttp://en.community.dell.com/techcenter/systems-management/f/4494/t/19653767 .

    Let us know if that helps.

    Thank you
    Vijay

  • Can I use "If", "else" statement in main.qml?

    Hello

    What statement I use within the main.qml?

    is there documentation for things and the statement can be used within the mian.qml (e.g. 'if', 'for', 'while')

    Hello

    Engine QML use a JavaScript interpreter.

    that statement is bug in Qt 4.8, so it is better to avoid it or explicit use of braces {} in the case branches. Other than that, it is simply JavaScript.

    Syntax information QML is located on the Web site of the project-qt:

    http://Qt-project.org/doc/Qt-4.8/qdeclarativeintroduction.html

    I suggest you browse the other articles there as well.

Maybe you are looking for

  • Button Portege A600 - 133 Windows 7 64 bit problem

    After installing windows 7 64 bit on Portege A600-133, Toshiba or Toshiba Assist button a presenter button work. All other keys are working properly. How can I solve this problem?

  • 2710 xi Back Upside Down under Vista with Duplex Page

    I saw where "Bob" helped others with printing backwards on the last page with Vista, using the duplex function.  My operating system is Vista Premium and my printer is a xi Photosmart 2710.  Can you help me with this problem?  I'm open to someone sen

  • When my laptop battery died the printer stopped working, now does not start

    The laptop screen went black, (while a print job is in progress) I plugged in and restarted the computer.  Since that time there no task sent to this printer have been achieved. I had to go back to my old HP882C just plugged into the 2side Print Setu

  • Upgrade of RAM HP 1140tu

    Hey guys!I am using kingston DDR3 at 1333 MHzI intend to move to COrsair vengeance 1600 MHz bus speed... can't I run in this laptop or not?any suggestions please

  • computer does not list the available wireless networks

    My computer is used to list all available wireless networks I could choose, but now not a list of people or don't allow me to search for available networks. I'm in a place where I know there is a wireless network available, however, my computer will