Your question seems a little vague - what exactly do you mean you want to be "better" at writing calculations? Do you want to know how to make your calculations simpler? Faster? Easier to read? Are you having trouble understanding how to go from input to output? The way you phrase your preamble makes me think you want to know how to get from input to output, but I'm really not sure.
Maybe if you posted an example, the board could take a crack at it?
MOstly, i see Calculations being written in MANY areas. Some are used in Field for Field Calculations,
others in custom functions
Others are in scripts.
For example . i JBante's Crumb script he is calling a let to do the following;
#For each page...
Exit Loop If ( Let ( $k = $k _1 ; $k > $pageCount ) ]
To me this is genius but simple if you look at it. I mean There isnt much documentation except using built in filemaker functions. Guess i am just thinking out Loud, but To make it really Simple here is what one has to do in order to write a calculation or function,etc
- What is my problem?
- Try to "WRITE IN PLAIN TEXT" how to find / fix problem
- Figure out what context to fix problem in . ie; script or CF or Calculation or Relationships
- Keep It Simple SimoN! KISS MEthodology
Is that pretty much it in a nutshell.
If So, what should i learn first. Filemaker Built in Functions or shall i just test other peoples calculations /functions to figure what they are doing and replicate as best i can.
on 2011-12-15 09:58 ian.moree wrote
Can someone please help guide me in figuring out how to be better at writing calculations or
Is it to just try things and see what works& what doesn't.
this is a basic skills-development question; i don't know your background, but
developing coding skills will depending on aptitude and practice; in general,
i've seen a lot of non-programmers gain programming skills by seeking examples,
comparing and understanding them, and by being persistent; having a mentor
and/or joining a user group (meatspace as well as online) helps too
FileMaker is a quirky system for software development, in part because a full
solution is never fully written down in code (much of it is done in
relationship diagrams, layouts, etc.), so it can be hard to describe verbally;
for that reason i would seek example solutions to download and explore
what should i learn first. Filemaker Built in Functions or shall i just test other peoples calculations /functions to figure what they are doing and replicate as best i can.
Steve has given you good advice. As you have observed, you see calculations written in a lot of different places [scripts, custom functions, field calculations, etc.] Start by learning the functions and then add to your understanding by exploring example files.
As files grow more complex, it will be difficult to follow the logic without a basic knowledge of functions and their capabilities. It helps to know them all, but I recommend the Text, Number, Date, Aggregate and Get functions as a basis. The FileMaker Help file will be a good resource here if you have no others. Each function is described with examples making it easy to try it out and test your understanding of the function.
You can study the starter files included with FileMaker. Most are not complex, but there are formulas to review and scripts to follow.
Don't miss the Technical Resource Library at this site. There are lots of interesting example files shared there. And take advantage of the offer to purchase The FileMaker Training Series for FileMaker 11 ($9.99 until Jan 31, 2012).
It's almost like asking, "How do I construct a sentence? How do I know which words to use?" Well... you learn which words exist, and what they mean, and you learn how to string them together using grammatical rules so they make sense. IOW: it's like learning a language.
Here's a recent post that sort of addresses your more specific questions:
fixed link, I hope --Tom