If white does not calculate then?

I'm trying to create a script for calculating customized for a discount (in dollars) field, where it takes the value of a master of reduction field (in %) of times the quantity of the item by the price. The problem is that I have the discount master field will be empty if no value should be entered and this seems to interrupt the calculation. I'm quite inexperienced with javascript so I'd appreciate it if you could take a look at my question and let me know what I need to do to solve this.

It's the simple formula that I need to get the total required:

(QTY1*UnitPrice1)*(Discount1/100)

I'm trying to say that if the value = white/null then do not perform the calculation recite (A * B) *(C/100):

if (this.getField("Discount1").valueAsString=="") then ???
else event.value = ( this.getField("QT1").value * this.getField("UnitPrice1").value ) * ( this.getField("Discount1").value / 100 );

Thank you!

If (this.getField("Discount1").valueAsString == "") event.value = "";

else event.value = (this.getField("QT1").value * this.getField("UnitPrice1").value) * (this.getField("Discount1").value / 100);

Tags: Acrobat

Similar Questions

  • Elitebook 6930p Wireless does not work then in the docking station

    Elitebook 6930p Wireless does not work then in the docking station, no idea how to fix this? It worked, then I got a soft image, not its broken.

    Visit this link

    WINDOWS XP - network connection turn off/on docking station

  • My wireless mouse just stopped working. I can still use the mousepad however. I changed the batteries does not. Then I tried another mouse wireless, and it didn't work either.

    My wireless mouse just stopped working.  I can still use the mousepad however.  I changed the batteries does not.  Then I tried another mouse wireless, and it didn't work either.  What can I do next?

    Buy an inexpensive wired USB mouse for less than $5 and see if it works.  As far as I'm concerned wireless mice are more trouble than they are worth.  YMMV :-)

    Good luck.

  • My creative application of cloud does not load then I'm connected with my Adobe all identification code suggestions?

    My creative application of cloud does not load then I'm connected with my Adobe all identification code suggestions? The icon in the menu remains grey...

    Schermafbeelding 2015-08-18 om 14.06.18.png

    Please check the steps mentioned in: https://helpx.adobe.com/creative-cloud/kb/creative-cloud-app-doesn ' t - open.html

  • FDMEE mapping < white > does not / Jython Script

    Hi all

    Has anyone got the < white > mapping work?  I put it in my SIMILAR mapping and it does nothing.  Any help would be appreciated.

    As a solution, I tried to add an import script to my base file import format.  I want it all empty fields in PKI to convert in [no PIC].  Keep logs process details (see below) gives me an error.  He doesn't seem to like dealing with NULL values.  Here is my script to import of Jython:

    def OracleEBS_ICPNone (strField, strrecord):

    If strfield is not nothing and len (strfield) > 0:

    return "[ICP None]"

    Another thing:

    return strfield

    Error log:

    2014-06-03 14:57:18, 892 [AIF] DEBUG: 105039:EPMERPI - error expression evaluation: OracleEBS_ICPNone (", 725, 100151_C, 000, 16434308.16')

    result: null

    2014-06-03 14:57:18, ERROR 894 [AIF]: 105039:EPMERPI - 105042:EPMERPI - error evaluating script.

    null

    THX,

    Mike

    How are your values of source?

    does not refer to NULL.

    This will work only if the value of your source has a blank space.

    So if you have a map as --> [no PIC]

    and your source is an empty string... it won't

    It won't work if it has a white space (' ')

    For you the script:

    def OracleEBS_ICPNone (strField, strrecord):

    If strfield is not nothing and len (strfield) > 0:

    return "[ICP None]"

    Another thing:

    return strfield

    Jython is case-sensitive: strField <> strfield

    If you want to capture values empty source in PKI:

    def OracleEBS_ICPNone (strField, strRecord):

    # You can cut your source, remove the whitespace on the left/right and then check if the length is zero

    If len (strField.strip () == 0:

    return "[ICP None]"

    Another thing:

    return strField

  • Essbase does not calculate number after 10 digits

    It's on version 11.1.2.1, cube Essbase BSO.

    In Essbase data loaded regardless of the number greater than 99,999,999.99, the system starts dropping numbers and rounding. In other words, it seems that Essbase wants to store a maximum of 10 digits, so we start to have problems with the numbers who have 11 or more digits. See below, for example.

    Data loading the data into Essbase
    Account 1 83,613,9500.13 83,613,9500.1
    2 634,269,675.79 634,269,675.7 account

    And of course total wrong, above 2 number total must be 1,470,409,175.92, but he is 1,470,409,175.80 what he does not last 3 & 9 and its ruling 10-digit.

    Please let me know if I need to make changes or I'm missing something.

    This give a try. Make a copy of your plan. Then, lock & load 2 values in question. Do not run the calculations. Export the entire database to a file. Finally, open the file in a text editor and find your values. This should ease your mind on what can store Essbase.

    BTW, I entered your values in base/sample without problem.

    Dave

  • Auto-Sleep does not work then in the lock screen

    As the title says, I set automatic standby after 30 minutes of idle time of the computer, but it only works when I'm on the desktop, if I'm not connected (lock screen), auto sleep does not work, how can I solve this problem?

    Hello

    A power plan is a collection of hardware and system settings (such as the display, sleep, etc.) who manages the way your PC uses power. Lock screen the console after the deadline option must be added to the advanced power settings.

    Change power management and check.

    Power plans: frequently asked questions.

    http://Windows.Microsoft.com/en-in/Windows/power-plans-FAQ#1TC=Windows-8

  • I tried to install GamingSDK1.4 and it does not open. then I went to control panel under windows uninstall 8 and its still on Creative cloud and I can't reinstall it

    Yesterday I installed GamingSDK1.4 and it does not open after completion. I've walked by an officer of Adobe to uninstall, I did. Returned and he was always there, but instead of saying open next to him, he says "up to date" I can't uninstall it. I want to reinstall it to use.

    http://helpx.Adobe.com/creative-cloud/KB/AAM-lists-removed-apps-date.html

  • PowerCLI does not calculate the Date year statement

    Hello

    I have a custom to attribute Date (JJ/MM/AAAA) in vCenter and I attempt to bring together WHAT VM before that date but does not my statement appear to account for the year.  So if I put a date in the future for example 15/01/2012 the script lists than before the current date is incorrect and everything goes back beyond the date of the day but still in 2011 is not displayed is correct.  Any ideas would be greatly appreciated.

    $currentdate = get-Date
    $currentdate = $currentdate. ToShortDateString()

    Get - VM | Get-Annotation - CustomAttribute "Expires"? {$_. Value - the "$currentdate"} ' "

    Version:

    vCenter - 4.1.0.12319

    PowerCLI - 4.1.1.2816

    See you soon!

    Have you thought about converting the date you get the attribute.  Try this

    $currentdate = get-Date

    Get - VM | Get-Annotation - CustomAttribute "Expires"? {(Get-Date $_.)} The value) - $currentdate}

  • Upward does not finish then save himself off

    My phone has not been saved for 90 days, it is said even if I started doing a few times last night, I put it (backup now) he saw half way did get then proceeded to bed this morning, has not himself (to the top (a) and not been supported for 90 days? right... some advice?

    What are you trying to save up, iCloud or iTunes on your computer. You have enough space in that that we must accommodate a backup of your phone?

  • Dynamic array sum does not calculate to commit

    I use the code for a dynamic table in summary below.  Whenever I have add a second line "Table1.Row1", then select the value that would make countU == true 0, the Livecycle form will not re - calculate the query properly unless I re - select the first line "Table1.Row1" countU value.  In other words, the PivotTable has two levels of expansion.  When I try to add more line under each primary line, the calculation is not executed automatically.  Any suggestions?  Thanks in advance!

    var sumD = 0;
    var countS = this.resolveNodes("TableA.Row1[*].Subform2[*].Table1.Row1[*].MBRS");
    var countT = this.resolveNodes("TableA.Row1[*].Subform2[*].Table1.Row1[*].NON");
    var countU = this.resolveNodes("TableA.Row1[*].Subform2[*].Table1.Row1[*].CLC");
    for (var i = 0; i < countS.length; i++)
     {
    if(countU.item(i).rawValue==0) 
    {
    sumD += (countS.item(i).rawValue * countT.item(i).rawValue);
    }
    }
    sumD
    

    Hello

    I'm not sure that understand your structure, you seem to have an inner repeat subform then a repeating table, which would be at three levels.  Anyway you will need to reference the count property of instanceManager to the calculation script knows to run when the value changes, so something like;

    var SUMD = 0;

    var tableARows = this.resolveNodes ("TableA.Row1 [*]")

    for (var i = 0; i)< tablea._row1.count;="" i++)="">

    var tableARow = tableARows.item (i);

    var table1Rows = tableARow.resolveNodes ("Subform2.Table1.Row1 [*]");

    for (var j = 0; j)< tablearow.resolvenode("subform2.table1")._row1.count;="" j++)="">

    table1Row = table1Rows.item (j);

    If (table1Row.CLC.rawValue == 0) {}

    SUMD += table1Row.MBRS.rawValue * table1Row.NON.rawValue;

    }

    }

    }

    SUMD;

    Concerning

    Bruce

  • Search option does not. Then appears the watch "is not responding.

    Hello all. From the Start button, I've always been able to type anything in the box search and find an answer. I usually clean my read-ahead this way. For the last days of the trial, the research program opens again when you type whatever it is, click on 'Search' a stop button appears and then another window will open to display, "the program addresses do not. Other auto updates I've nothing changed in the system. Am running XP on an IBM. Help would be appreciated.

    Hi Homersit,

    What is the result of the second Fixit?

    Method 1:

    You can read the article and try to run a disk check.

    How to perform disk error checking in Windows XP

    When you run the disk check, there are chances of losing the data that you can take a backup before running the disk check.

    Method 2:

    You try to open the Task Manager and then try to Search.

    a. click new task.

    b. in the create task dialog box, click Browse, locate and select the program that you want to start, click Open, and then click OK.

    c. or type the name of the program, a document, or a folder, and then press ok.

    Also check if there is a particular process, using all the resources at the time of the question.

    For more information, see the article:

    How to use and troubleshoot issues with the Windows Task Manager

  • New folder option doesn't work does not and then right-click new folder option missing.

    "New folder" option in windows Explorer 7 does nothing when selected.  Right click menu is not a "new folder" option.  Can someone help me?

    You are welcome.

  • HP pavilion dv4 (1287cl) computer laptop laptop gets hot and does not load then

    Hi guys, my hp pavilion dv4 1287cl gets hot and the fan emits noises.
    WHN it has fully charged so I remove the plug charger and it's cold as hell. This only happens when it's warmer and the fan makes noise that is made all day.i use for programming and playing games like minecraft. also it is not sometimes load when it is warmer more when the fan is the production of abnormal voice.

    I'm started to get upset with that I had broken the screen and keyboard (but had then replace them) because it makes him angry.

    I live in pakistan so u kn on load shedding and the electriccity turns off like after like every 8 hours and it freezes.

    Please help me guys.and thanks for reading this story together soft

    Hello

    Click on the link below:

    The fan runs constantly, the PC is running more slowly than expected and generates heat

    Note:

    We suggest that you should try to update the Bios.

    The update of the Bios?

    Download the latest update of the Bios for your model specific here.

    Connect the power adapter to the netbook.

    Disconnect from the Internet. Close all running programs. Disable anti-virus and firewall.

    Double-click the Bios update exe file. It may take some time, so it is important to remain patient, not to interrupt the process. Allow the laptop to restart after applying the BIOS update.

    Although this update is running are not:

    • Turn off your laptop,
    • Disconnect the power adapter,
    • try to run any software or do anything on the laptop.

    Note:

    The Bios update process is always risky. You do this at your own risk.

  • The recommended action to correct security with SE 7 U does not work, then?

    I kept getting the Java SE 7 U plugin has problems of message security. I uninstalled both 32-bit and 64-bit and then installed again. I get the same message on the security of the poor. I use it for my crossword days online. Is the problem with www.independent.co.uk or my PC?

    Hello timgall, the java plugin has a record of questionable security in general. If you want to enable it for some sites, you can do it-for more details see How to enable Java on trusted sites

Maybe you are looking for