Skip navigation
mstout@edwardrose
Currently Being Moderated

"If" forumla help please!

Aug 7, 2012 9:51 AM

I am trying to create a conditional or "if" formula in Acrobat.  I have successfully done the same thing in Word, but the same formula will not work in “Simplified Field Notation” and I am not too familiar with JavaScript.

 

My fields are "install", "monthly", "day", "dayrate" and "prorate".  ("monthly" and "install" are the only fields that require input from the user.

 

dayrate = monthly / 30    day = 31 - install

 

I am trying to determine "prorate" based on what is input in "monthly" and "install."  The formula I used in Word to calculate the value for the field “prorate” is “IF(day=30, monthly, day*dayrate).

 

Is there a way to do this in Acrobat? I have tried mimicking several other “IF” scripts without success and I’m in a time crunch.  Thank you much!

 
Replies
  • Currently Being Moderated
    Aug 8, 2012 9:04 AM   in reply to mstout@edwardrose

    The simplified field notation is not JavaScript but uses JavaScript behind the scenes to take the field names and constant numeric values to perform the four basic calculation methods of addition, subtraction, multiplication and divsion. No conditional controls statements, field properties, field methods, or functions are allowed. Field names must start with an alphabetic character and should not include any white space. White spaces are used to determine the break of field name, operations, and constants.  String operations are also not permitted.

     

    You do not specify the target of the calculation, as it is assumed the target for the result of the calculation is the field for which the calculation is being written.

     
    |
    Mark as:
  • Currently Being Moderated
    Aug 8, 2012 9:33 AM   in reply to mstout@edwardrose

    You have a conditional situation and Simplified Field notation can not perform that type of statement, You will need to write a custom JavaScript callculation.

     
    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points