You are viewing limited content. For full access, please sign in.

Question

Question

Form invoked from Workflow not performing lookups

asked on April 10, 2024

We have an external system that finishes its process by using the SDK to create a document in the repository.  There is a workflow watching for this document.  The workflow starts and manipulates the data, the majority of which is a json.  With freshly parsed json data the workflow performs an Invoke Business Process action to load data into a form.  The form loads with all of the starting variables.  The form is then passed on to the first of several departments for approval. 

I'm running into trouble on the first form.  The main lookup key is StudentID.  There are a few lookups that should perform using StudentID.  I'm not sure exactly what is happening but I believe that the lookup may be starting before StudentID has been populated with the starting variable value.  That seems to make the most sense since all of the values that should be returned are blank.  If I move the lookups using StudentID to the first approval form, it works just fine.  Unfortunately, I need to send some emails using that looked-up data before I reach the second form.

I've tried triggering changes on StudentID with jquery, but that didn't work.  I've tried forcing a 5 second delay and then triggering change on StudentID, but that didn't work.  StudentID has it's value that was passed in as a starting variable, I'm just not able to successfully use it in a lookup.

Any ideas?

 

0 0

Answer

SELECTED ANSWER
replied on April 10, 2024

Workflow does not submit a form, it just sends data. Lookups and Javascript and such do not run if there is no users loading a form. If your starting form flows into an email task directly, then what you are seeing is expected behavior.

3 0

Replies

replied on April 10, 2024

When you say "The form loads with all of the starting variables.", is this a user task that this happens at or are you just seeing the variables being set by Workflow?

0 0
replied on April 10, 2024

It is not a user task.  I can see the variables set by workflow.  It is the starting form for the business process.  When it finishes I have it email me a pdf of the form and you can see the holes where there should be looked-up data.

 

 

0 0
SELECTED ANSWER
replied on April 10, 2024

Workflow does not submit a form, it just sends data. Lookups and Javascript and such do not run if there is no users loading a form. If your starting form flows into an email task directly, then what you are seeing is expected behavior.

3 0
replied on April 10, 2024

Yep, what Miruna said. If you want those girls populated, have Workflow do the lookups for you and pass the values to the Forms instance.

0 0
replied on April 11, 2024

That wasn't exactly the answer I was hoping for, but I can work with that. smiley Perhaps being able to start a lookup when a form is invoked is not such a bad idea.  

Currently, it will take some additional work to make that data available on the workflow side for us, but is already available on the forms side.

 

Thanks for the info!

 

0 0
replied on April 11, 2024

The lookups have to be triggered somehow.  Like Blake said, WF can do this for you.  We use custom queries and just spit all the data into the Invoke Business Process.  I do feel that activity could use some "love" and be improved for ease of use.  If you have a lot of data that needs to be on the form, it is very tedious and messy to look at.  I have a lot of forms that are started by workflow that have a lot of data in them so I feel your pain.

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.