You can try this link: http://help.adobe.com/en_US/livecycle/9.0/lc_dp_list.html and under the "Creating Forms Using LiveCycle Designer ES2" heading, you can find a variety of documentation resources that include a basics guide and reference material.
Hope that helps!
I'm looking for a description of how to create a custom function within LS then
call it from various events.
The pointer you sent has lots of info but I don't seem to be able to find what
I'm not sure what I want to do can even be done within LS, do you know?
Sorry, what is LS? Do you mean LC, for LiveCycle?
If you click on LiveCyc'e Designer ES2 Scripting Basics, there is a section on Events. That section may have some of events information you seek. There is a entire Application model available that let's you key in on different types of events that include Application events and form interaction events. What are you trying to accomplish?
Sorry, meant LC.
I have to exec some complex code at both prePrint and preSave events (maybe also others) and am looking for a way to only write it once then execute it when I need it. A custom (global?) function may be one answer but I don't know how to create it.
Is there some other way?
As Paul mentions (Thanks Paul!), it is well described in the Designer Help.
Here's a direct link to the Scripting section in the Designer Help: http://help.adobe.com/en_US/livecycle/9.0/designerHelp/index.htm?content=000715.html#1613857.
Other subtopics that may help you with what you seek based on what I think you said you were trying to accomplish:
Feel free to look at other topics in the Scripting section. It is fairly comprehensive. If not, providing a snippet of code might help as well.
I presume you are familiar with working with the Scripting environment in Designer ES2. If not, there is a small calculation tutorial that shows you how to use the Script Editor (http://www.adobe.com/go/learn_lc_subtotals_9).
Hope that helps!
You want to put your JS functions in a Scripting Object. If you don't see one at the bottom of the hierarchy list, right click the root and add it. Then put the code in this one place and call it from one to many places on your form.