Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

Tabbing is Sloooooow

Avatar

Level 4

I've designed a 78 page dynamic document that takes in a lot of data. The major problem is that when someone enters data moving from one field to the next is really slow. There are about 10 lines of script with these fields. I have followed all the helpful hints to streamlining my code and documents, but the tabbing is still very slow. Any ideas as to getting the tabbing to respond quicker?

9 Replies

Avatar

Level 10

Hi,

That's a big form. What events have script? If you have a lot of script in the layout:ready event then that could be part of the problem. Even a Page n of m object on the Master Page includes TWO layout:ready events firing 78 times EVERY time a user exits a field. See example here http://assure.ly/nB0Bvz.

Niall

Avatar

Level 4

I don’t have anything in layout:ready. I do have code in doc:ready.

Gary D. Cooper

IDOA - IT Applications Manager

1 Natural Resources Way, Suite 100

Springfield, IL. 62702

(217) 558-0139

Avatar

Level 10

Hi Gary,

The doc:ready event should be okay because this event fires only once when the form is first rendered. After that it does not fire.

Do you have a page numbers on the Master Page?

What is the script doing?

Niall

Avatar

Level 4

No page numbers.

The script takes a last name field and adds it to the first name field to make a full name that is an invisible field that I can use latter in the document.

ClientName.rawValue = ClientFirstName.rawValue + " " + this.rawValue

That’s all it does and then there’s like a 3 to 9 second delay between the last name field and the first name field.

Gary D. Cooper

IDOA - IT Applications Manager

1 Natural Resources Way, Suite 100

Springfield, IL. 62702

(217) 558-0139

Avatar

Level 10

I suspect there is a conflicting script. It sounds like it is in a loop, which gets thrown out after so many iterations. Is this the only field that goes slow?

If so, then search through the XML Source tab looking for other instances of the object names. This may throw up other scripts.

Niall

Avatar

Level 4

There are no loops in the scripts that I have written. The only fields that are slow are the ones with scripts in them.

Gary D. Cooper

IDOA - IT Applications Manager

1 Natural Resources Way, Suite 100

Springfield, IL. 62702

(217) 558-0139

Avatar

Level 10

Hi Gary,

Last thing I am going to recommend is that you add a trace to a COPY of the form and then run this and see what scripts are firing.

John Brinkman has an excellent marco script to add a trace to all scripts. Marcos were added in LC Designer ES2 and supported in ADEP Designer 10. You will get more information on John's blog here:

http://blogs.adobe.com/formfeed/2010/06/add_trace_to_form_script.html

TextEdit.png

Good luck,

Niall

Avatar

Level 4

I went and removed most of my scripts and it has sped the tabbing up dramatically. Why would it slow down so much just trying to combine a first name field and a last name field into a full name field, is beyond me. Or when you try to combine a address1, address2, city, state, zip into a full address field. This isn’t very workable. We might as well of just written it in VB or Java.

Gary D. Cooper

IDOA - IT Applications Manager

1 Natural Resources Way, Suite 100

Springfield, IL. 62702

(217) 558-0139

Avatar

Level 10

Hi Gary,

I have forms with loads of script that run very smoothly. The issue to bear in mind is what events you use when developing script AND how efficient the script is.

This is a version of John Brinkman's example: http://assure.ly/zubx8H. See full description here: http://blogs.adobe.com/formfeed/2011/10/script-performance-exercise.html.

Also see John's post on copying data across fields: http://blogs.adobe.com/formfeed/2011/10/moving-code-into-a-shared-script-object.html.

I suspect that there was a conflict somewhere in the script or that it was trying to resolve the object names.

Hope that helps,

Niall