Field calculations

Mark Wieder mwieder at ahsoftware.net
Wed Sep 11 13:38:41 EDT 2013


Vaughn-

Wednesday, September 11, 2013, 10:26:12 AM, you wrote:

> I am a database developer so I am new to LiveCode. I used the dictionary
> trying to do the following but the Hypertalk script approach is not clear.

Not a problem. Basically you've already written the code by describing
it in pseudocode:

> I simply want to take one field and use a math operator to say add two
> fields together and put the result into a third field.

> Example: Loan amount + loan fees = Sum amount of loan

put field "loan amount" + field "loan fees" into field "sum"

> I might want to add 3 fields together and then subtract a different field
> from the sum of the 3 fields.

put field 1 + field 2 + field 3 - field 4 into total

> Or take a loan percentage * the Loan amount to get the amount of interest

put tLoanPercentage * tLoanAmount into tInterestAmount

-- 
-Mark Wieder
 mwieder at ahsoftware.net





More information about the use-livecode mailing list