swetzel

New to Filemaker, How do I do set a field to a calculated result?

Discussion created by swetzel on May 3, 2017
Latest reply on May 4, 2017 by swetzel

I am trying to set a field (call it "Result") to a complex calculation.  I want to do something like this:

 

If DatabaseField:Type = "A" {

     many lines of calculations giving Answer
} else if DatabaseField:Type = "B" {

     many lines of calculations giving Answer

} else if DatabaseField:Type = "C" {

     many lines of calculations giving Answer

} else if DatabaseField:Type = "D" {

     many lines of calculations giving Answer

Put Answer into Database:Result

 

The question is, how do I do this in Filemaker?  I would like to use constants and variables in my calculations but I cannot figure out how to do it? Should I use a script?  Should I use the calculation window for a field?  Can someone help me get started with the right syntax?

Outcomes