Speeding Up E-form Loading – Part 2
In our previous article “Speeding Up E-form Loading – Part 1“, we discussed speeding up E-form loads by replacing DMGETOPTIONS with Server Data calls. This is a great way to speed up loading dynamic lists. In this article, we will focus on another way to speed up E-form loads. The second culprit to slow E-form loading is using too many DMGET calls.
Pulling in Data
DMGET is a great way to do a search in a single call. It fits nicely into a field’s default value, so it is easy to implement in an E-form. The problem is, each DMGET does its own search. If you use too many of them, it will slow down the E-form load. Imagine having an E-form with 5 DMGET calls. That means the E-form is doing 5 full searches BEFORE the E-form can even load. This can be a very slow process and not a very nice use experience.
Replacing DMGET
The first thing we suggest doing is trying to find another way to get your data. If the data you are looking for is something that can be cached, then you can follow the same Server Data principals we talked about in the Part 1 article. Cache the data in a Server Data variable and use that instead of the DMGET in your E-form fields’ default values. Read the Speeding Up E-form Loading – Part 1 article for all the details.
Using Workflow
The other suggestion we would have would be to see if the data is able to be pulled in via some other means. If your E-form is being loaded from within a Record then you may be able to pull the data into the Record before the E-form is needed. Maybe bring the data into the Record via a DMGET or using workflow during a less time-sensitive part of your process.
For instance, imaging you are doing AP approvals via the E-form. In the E-form you want to display the Vendor information by using the Vendor ID to go search up the vendor address, etc. Instead of using DMGET to do that, use the workflow actions to bring in the data during the process before it gets to the user. That way the lookup has been done ahead of time and the user does not need to wait.
Just place the data into a Record field then use that Record field’s name as the default value for the E-form field.
Deferring the Lookup
Another great way to speed up the DMGET use is to defer the calls to DMGET. Allow the E-form to load and then use a timer or multi-action field to trigger a call back to the server to get the GMGET data. You can do this by building an Action Set that uses DMGET in a Set Return Data action.
Related Articles
Speeding Up E-form Loading – Part 1