Clear up a few questions from a new user

I am quite new to applescript and had decided to learn it using all online resources (Im not buying any books!) Now I am familiar with some scripting languages like PHP but I am finding apple script a little hard to grasp because of the unusual terminology in the documentation (eg an Array is now a List), and also I can never work out if I should use an “as”, “of”, “in” or “is” in my syntax.
I quite frequently come across new commands in example scripts but find that these are not located in any of the main dictionaries… Is there anywhere that has a complete list of all the built in commands for applescript and a description as to what they do?
Also I cant seem to find how to make built in functions… am I missing something? I shouldn’t have to repeat code.
Thanks for your help.[/b]

As far as functions go, you just use the keyword “on”


on myFunction(param1, param2)
  --do stuff
end myFunction

on the end part, you don’t even have the function name again. The compiler will put it there for you.

If you are looking for a listing of all the commands for Applescript, you can find some links here, I believe, that will lead to the Applescript language guide. This is a little dated, since I think it was originally published in 1999, but it will get you going. You might also want to look here for more info:

http://www.apple.com/applescript/resources/

There is plenty to be learned at the link above!

Don’t get bogged down on the “little words” in the syntax. Just remember that Applescript was originally aimed at non programmers, so the syntax is supposed to allow for more “english like” programming. There are many examples where this doesn’t seem to hold up and the “simple english like statements” are rather convoluted and not very natural.

The biggest problem for me, is the variability of the syntax from one application to another. There are very different ways to script applications which makes it tough to figure out sometimes. I struggled for a long time with ScriptEditor, and now that i have switched to Script Debugger, things are a LOT simpler to figure out, from one application to the next.