shorten the few lines of codes with a loop for?

Hello, I have a few lines of code I want to shorten.

, Someone has any idea how to make this right?

Thank you!

:

Tags: Adobe Animate

Similar Questions

  • Please explain CVI question #335358: using the operator of bit-shift twice on the same line of code produces incorrect results

    Hello

    I just stumbled on http://www.ni.com/white-paper/12323/en#335358_by_Category.

    With the help of the bit-shift operator twice on the same line of code produces incorrect results.
    Workaround: Separate the operations of shift of two bits in two distinct lines of code.

    Reported Version: 9.0    Solved Version: N/A    Added the: 14/02/2012

    Could someone please explain what kind of construction causes such a question?

    I have not noticed problems again and not have not noticed or found a thread about it.

    Thank you.

    The reported scenario looks like this:

    unsigned int a = 1, b = 62;
    unsigned  long long result = 1ULL << a << b;
    

    The problem arises because of the temporary variable used when do two little is placed in the same line. This separation into two lines will produce correct results:

    unsigned int a = 1, b = 62;
    unsigned  long long result = 1ULL << a;
    result = result << b;
    
  • How can I get rid of the 2nd line of signature with an email requested line under form after its creation in a widget

    So I created a widget or a hosted form, and after finishing to complete to have a single view of signing, he puts another section or area below which requires another signature and send an article I don't want to have there. It creates another page as well because my original signature line is down.

    Then... How can I get rid of the 2nd line of signature with an email requested line under form after its creation in a widget

    Hello

    By default the Widget to always an email and if you have not added field which, E-Sign would put a signature block (which consists of Email field) at the bottom of the document.

    Kind regards

    -Usman

  • When you open a new session and after a decline in all the video files in the content area (the sound and the video is very good). After you have chosen a selection of clip the first clip that I post on the time line is equipped with sound. then the next

    When you open a new session and after a decline in all the video files in the content area (the sound and the video is very good). After choosing a selection of clip, the first clip that I post on the time line is equipped with sound. then the next clip, I chose (not dose issue)
    will have no sound. (but in the contact box everything its fine) Why is this?

    Why is this?

    Because you forgot to patch source audio track.

  • How to disable certain fields in the form of a calculation with a checkbox for the fields.

    How to disable certain fields in the form of a calculation with a checkbox for the fields.

    In Canada, we have taxes

    I create a form that allows them to calculate a total

    Shema-pdf-form.gif

    I need to be able to turn off all of those taxes to participate in the calculation and to their field visible should be 0

    I was thinking about using a check box (when the checkbox is enabled (Yes) the tax is calculated, unchecked (Off) the tax is not calculated and visible field should show 0 or anything...)

    I really need help on this one, I am a complete newbie...

    Note that the second tax is calculated on the sum of what the first tax Add (tax first is pan-Canadian tax (all provinces).

    The second tax is never only use (Quebec only (in addition to one Canadian)

    Sometimes to sell outside Canada - no tax at all is calculated...

    What should I do?

    Yes, it's just the JS...

  • sqlplus connects well with SID on the command line, but not with setora

    I can connect to my database using sqlplus if I specify the SID on the command line; However, I get an error if I try to connect after using setora to set the SID. Any ideas on why this is happening?

    Oracle version is 10.2.4.0
    OS is SunOS 5.9 Generic_122300-46 sun4u sparc SUNW, Sun-Fire-V490
    MYDB resides on a host machine that is different from the one where I'm under sqlplus. We'll call this REMOTEHOST machine.
    I am sure that MYDB is running on REMOTEHOST
    MYUSER@MYHOST% setora MYDB
    MYUSER@MYHOST% sqlplus MYUSER
    
    SQL*Plus: Release 10.2.0.4.0 - Production on Mon Mar 8 09:38:58 2010
    
    Copyright (c) 1982, 2007, Oracle.  All Rights Reserved.
    
    Enter password:
    ERROR:
    ORA-01034: ORACLE not available
    ORA-27101: shared memory realm does not exist
    SVR4 Error: 2: No such file or directory
    
    
    Enter user-name: ^C^C
    MYUSER@MYHOST% sqlplus MYUSER@MYDB
    
    SQL*Plus: Release 10.2.0.4.0 - Production on Mon Mar 8 09:39:10 2010
    
    Copyright (c) 1982, 2007, Oracle.  All Rights Reserved.
    
    Enter password:
    
    Connected to:
    Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bit Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    
    SQL> quit
    Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bit Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    Oracle environment variables:
    MYUSER@MYHOST% env | grep -i ora
    PATH=/u01/home/bin:/u01/app/oracle/product/10.2.0/OPatch:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/opt/lib/cobol/bin:/usr/ccs/bin:/opt/SUNWspro/bin:/banvol/uncg/bin:/etc:/usr/openwin/bin:/opt/hsqr/ora/bin:/opt/hsqr/jre/jre141/bin:/u01/app/oracle/product/10.2.0/bin
    SQRDIR=/opt/hsqr/ora/bin
    LD_LIBRARY_PATH=/usr/ccs/lib:/opt/lib/cobol/lib:/opt/SUNWspro/lib/v9:/opt/SUNWspro/lib/v9:/opt/SUNWspro/lib:/u01/app/oracle/product/10.2.0/lib:/opt/hsqr/ora/bin:/opt/hsqr/jre/jre141/lib/sparce/native_threads:/opt/hsqr/jre/jre141/lib/sparc/client:/opt/hsqr/jre/jre141/lib/sparc:/u01/app/oracle/product/10.2.0/lib32
    ORACLE_BASE=/u01/app/oracle
    ORABIN=/u01/home/bin
    OWB_HOME=/u01/app/oracle/product/owb102
    ORACLE_SID=MYDB
    ORACLE_HOME=/u01/app/oracle/product/10.2.0
    TNSNAMES entry:
    MYDB =
      (DESCRIPTION =
        (ADDRESS_LIST =
          (ADDRESS = (PROTOCOL = TCP)(HOST = REMOTEHOST)(PORT = 1521))
        )
        (CONNECT_DATA =
          (SERVER = DEDICATED)
          (SERVICE_NAME = MYDB.MYDOMAIN.COM)
        )
      )

    TWO_TASK = MYDB
    Export TWO_TASK

  • I can access the internet in safe mode with networking; then for a short period in normal startup; but then I lose online access.

    Windows XP: internet connection

    Windows XP: I access to internet in safe mode with networking; then for a short period in normal startup; but then I lose access (IE8, Google, AOL) online. I tried several times, sometimes it seems able to stay online as long as I'm using the installation, but if I take a break, I lose access and return in safe mode.

    This question is submitted in safe mode with networking

    Hello

    Normal mode try to know what actually is the problem with the Internet connection and the components involved.

    Maybe this can help.

    For the wire connection - http://www.ezlan.net/debug.html

    For a wireless connection - http://www.ezlan.net/wireless.html

  • In any case, to use transform activity with a loop for storage of the iterative purpose?

    Hi all


    I have a question about the processing activity. As I am new to BCI, I want to learn more about the processing activity. If we use a transformation inside a loop activity, all other records other than the last ones will be overwritten. I want to avoid this situation and s output

    Scenario of
    -------------------------------

    (1) inside a loop for, I keep a DB adapter that will choose 1 row of table. So in each loop iteration for, we will get a line.

    (2) in the same loop, we maintain another DB adapter which will retrieve multiple records.

    (3) these values, I need to map it to an output variable (output xsd is able to contain multiple records) in the following order.
    < 1Adaptateur out >
    < data1 > < / data1 >
    < data2 > < / data2 >
    < 2 adapter output >
    < data > < / data >
    < data > < / data >
    < / 2 adapter output >

    for example)
    < Person > - 1 adapter Db I st iteration
    < name > xx < / name >
    < 23 > < / Age >
    < address > - 2nd iteration of st adapter 1 DB
    home address < address > < / address >
    address of the < address > < / address >
    permanent address < address > < / address >
    < address >
    < / person >


    < Person > - 1 adapter Db iteration nd II
    yy < name > < / name >
    < 23 > < / Age >
    < address > - 2nd iteration of st adapter 1 DB
    home address < address > < / address >
    address of the < address > < / address >
    permanent address < address > < / address >
    < / book >
    < / person >
    How can I pass the data that we have read from the db adapter in the above format

    Pls suggest a solution for this.

    Published by: user_ds on June 15, 2011 02:38

    Published by: user_ds on June 15, 2011 02:47

    HI'.

    1.) initialize a new variable 'counter' of type int, and assign inside initialize counter = 1
    2.) put the card1 DB and DB map2 invoke the of inside a while loop, then put it
    condition (that you want to use) for the number of times you want to hit the DB again and again
    3.) use affect the activity and inside this use Add and put the [$counter] on the expression of xsl to map to the next node
    4.) now use a beneficiary within an Assign activity where increment you counter + 1

    Yatan-

  • Facing problem in the recording of data without overlapping in loop for

    Hello

    I am facing problem in writing data withou overlap if I run the outer loop for the 2 times or more, and inside the loop, I make table in a way that I want to, but when I try to compile this table with record temperature I am not able to do. Please guide me through ths.

    Thank you

    Hnagpal

    Himanshu salvation,

    To start reading your matrix of the second line, you can use a table of Index function once you have loaded the table of your spreadsheet file. The function Array Index lie in the range of functions under functions > programming > Board Index. The help of LabView is very useful to explain how to use this function.

    With regard to the accuracy of the numbers when read you the spreadsheet file that you read is formatted in fractional chain, since form you it converted into a mixed string before saving. In order to recover all the precision, read the worksheet as a string and then convert it to a string using a string Fract/Exp to fractional numbers conversion function. This feature is on the range of functions for String > String/Number Conversion > Fract/Exp string in number. The help of LabView is also very useful for explaining the operation of this function.

    Best,

    Dan Nelson

    Technical sales engineer

  • Help with a loop For passing parameters...

    Hello

    I am creating four cubes in Papervision using a loop for. The cube class requires, as the first parameter, a MaterialsList. I created four different MaterialLists in my code with the names materialsList1, materialsList2, materialsList3 and materialsList4. In a loop for, I'm trying to pass these variables as MaterialsList parameter. It does not work. If I use the variables themselves in the code, it works fine, so I know that my problem has something to, with how I'm data, type the dynamic name (see Actionscript below). Can someone please? Thank you!

    The Actionscript code:

    for (var i: int = 1; i < 5; i ++) {}


    var cube: Cube = new Cube like MaterialsList (("materialsList"+i), 396, 40, 494, 8, 8, 8);


    container.addChild (cube);


    Cube.x = i * 430;


    cube.rotationY = 180;


    Cube.Name = "the cube" + i;


    trace (cube. (Name)


    cube.addEventListener (InteractiveScene3DEvent.OBJECT_OVER, objectOverHandler);


    cube.addEventListener (InteractiveScene3DEvent.OBJECT_OUT, objectOutHandler);


    cube.addEventListener (InteractiveScene3DEvent.OBJECT_PRESS, objectDownHandler);


    }

    You are welcome.

    If you're still able, please mark this thread as answered.

  • Ajouter.1 with a loop for?

    I tried to add du.1 increment a value using a loop for, but the for loop has not added to the value of the specific increments.

    So instead of se.1,.2,.3,.4, etc., I got the following when I traced it the loop:

    0

    0.1

    0.2

    0.30000000000000004

    0.4

    0.5

    0.6

    0.7

    0.7999999999999999

    0.8999999999999999

    0.9999999999999999

    This throws my code completely because it causes the loop to execute unnecessary once and the returned value causes other functions are not working well. Please advise on how to solve this problem.  I note that this is not a problem once you get a.25.

    use .toFixed (1); After the value

  • Assign variables with a loop for

    Hi all

    I'm variable loading for a quiz of xml using Ajax:

    $.ajax({)

    type: 'GET ',.

    URL: "loadVars.xml",

    data type: "xml."

    success: {function (xml)}

    The data that I get are the following:

    word1 = $(xml).find('word1').text ();

    word1distracter1 = $(xml).find('word1distracter1').text ();

    word1distracter2 = $(xml).find('word1distracter2').text ();

    word1distracter3 = $(xml).find('word1distracter3').text ();

    There are about 20 words and I want to use a loop for assign variables on both sides of the equation.

    for (var i = 1; i < 20; i ++) {}

    What's the syntax? I tried:

    "word" + i =

    eval("word'+i) =

    etc.

    Any help much appreciated.

    OK found!

    window ["word" + i] = $(xml).find("word"+i).text ();

  • What are the opinions of the developers on how best to manage the upgrade of the libraries of great code with several applications again a version of labview?

    I have a large set of code I have carefully migrated from version of one labview to another over the years.  I have a lot of deployed applications that I need to continue to support.  Of experience and interaction with other developers, I don't think I can continue to migrate each application to a new version of labview when I move in the future.  Each application seems to break in one way or another, the versions do not work right and need to be redone and its much too much time to get all my apps working and tested again.  This opinion is solidified by the policies of OR which make it impossible to install older versions of new versions of labview Toolkit, for example.  Compatibility is often sacrificed so NEITHER can develop labview in the direction they choose.  So I have to take the position that what version I have to write an application in will probably need to be maintained in this version of labview throughout his life.

    In this context, how are other developers management old application written in older versions of labview.  Right now I have a PC virtual on my system 7.1, 8.0, 8.2 and 8.5 running on different virtual PC so I can keep each installation separate.  I highly recommend this approach.  But keep my large libraries of separate code is difficult.  They are several GB, they all relate to each other, and I always get worried, even when I separate them into different directories that somehow labview will search in the wrong place and find the wrong version of a subvi.  Other people are also trying to keep copies separate from all their code in versions different labview?  How other people handle this problem?

    Hello

    The hierarchy of the following directories, coupled with a VI "hierarchical" naming strategy, have been effective (for me) to prevent "Crosslinking" through projects and versions of LV. The hierarchy of storage has been designed for use in an environment of CSC, but works very well regardless. Hierarchical naming ensures unique names for application-specific files. Library use of the project (in LabVIEW 8.x) addresses the problem of having different screw with the same name, yet, it gives me warm-ferrets have application-specific files named in a unique way and I can't imagine not use hierarchical naming more - he described the length in section 2.1 of the attached. doc...

    Note: It has been my experience that societies resources as well as specific support "programs", where a program is linked to a product or the "family" of products, so, under the (each subdirectory of "Program" below) encapsulates specific applications to the product (or family-specific). Assuming that no CSC tool is used the directory (below) is also, as depositary for distributables.  All the distributables necessary for the reproduction of a test station should be placed under .

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



    |
    | |
    | | |
    | | | |
    | | | |
    | | | |
    | | |
    | | |
    | | |
    | | |
    | |
    | |
    | |

    * Program-specific applications that have (probably) distributables
    |
    | |
    | |
    | |
    * Individuals, specific to the application, screws go here
    | |
    | |
    |
    | |
    |
    * Tools of are NOT "program" - specific and perhaps distributables
    |
    |


    |
    |
    | |
    | | |
    | | | |
    | | | |   Application_ #1.bld >
    | | | |
    | | | |
    | | | |
    | | | |     Application_ #1.llb >

    * Distributable is created from LLB 'snapshot', not directly to the development tree
    | | |
    | | | |

    | | | |    Application_ #2.lvproj >
    | | | |
    | | | |
    | | | |
    | | | |     Application_ #2.llb >
    |

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

  • Extract lines of code with RegExp

    Hello

    I need to extract the separate code "lines", where the line is a character set, end up ';' + a number of spaces and tabs + "\n" and I can't understand the RegExp right for the deal.

    Can anyone help?

    text to extract:

    firstUpperCase(str) = concat(
         uppercase(
              substr(str, 0, 1)
         ),
         substr(str, 1)
    );
    
    generateEventMethod(str) = concat(
         "dispatch",
         firstUpperCase(str),
         "Event"
    );
    

    desired output:

    MATCH #1:
    firstUpperCase(str) = concat(
         uppercase(
              substr(str, 0, 1)
         ),
         substr(str, 1)
    );
    
    MATCH #2:
    generateEventMethod(str) = concat(
         "dispatch",
         firstUpperCase(str),
         "Event"
    );
    

    Hello

    It might work to replace dot (any character) by ("[" ^ "] *" | ") [^']*'| [^;])

    He would treat strings in single quotes but without escaped quotes.

    You can then try to replace [^ ""] (except quotes) by (\. |) [^"])  ... Make sure you get the right number of backslashes

  • Sewing of instances of MC in the library's own code WITH!

    Hello again,

    I would like to load video clips from the library onto the stage.

    How can I load them with some code on them? I can already hear load with onClipEvents on them, as if I added myself to the stadium...

    Is this possible? and if so, how? via attachMovie?

    What do I have to use MCName.onLoad = function? and stuff like that? and if yes how to several video clips?

    Thank you,

    lol if you want to apply a method to your attached movieclip, you can use either:

    var mc:MovieClip = this.attachMovie ("yourmovieclipinstancename", "mc_id", s.getNextHighestDepth ()) thi;

    {mc.onPress = function ()}
    No matter what
    }

    or

    {yourmovieclipinstancename.onPress = function ()}
    No matter what
    }

Maybe you are looking for