Thom, I tried this several times and every time Adobe crashes and gives me some message about not being able to reference the memory. any tips? (I copied your example exactly only changing the field name) I am using Adobe 7 Pro -thanks.
Andrew D. Albrecht, MS
Solutions Developer
ING USFS
This is very strange. Something is very wrong with your Acrobat 7. It should not crash.
First, the answer I gave previously assumed that you are using AcroForms, as opposed to a LiveCycle Designer form. This code will not work at all for LiveCycle forms.
The next thing to do is to break the code into parts and run each part individually from the console window to see what exactly is causing the problem. If it all works from the console then place the same code back into the document with try/catch blocks (and proper error reporting) around each line.
After this you will know much more about what's going on and will be able to write a question with more details.
this.getField("MyField").userName = "This is my field";
This line sets the tooltip for a field named "MyField".
Thom Parker
The source for PDF Scripting Info
www.pdfscripting.com
Very Important - How to Debug Your Script