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

Question

Question

Need workflow to find the right forms instance

asked on November 22, 2017

I have a workflow that is activated by Forms.  It is working great, however, sometimes the approver changes the applicant's name before approving and this stops the WF from finding the right BP Instance (the application) to link up to the approved permit that the WF creates.

I know I can block the approver from changing the applicant's name, however, he's just trying to correct spelling mistakes, which is good to do.  I don't really want to stop that.

I'm wondering if I can somehow change how the WF finds the application.  It currently is told to look in a specific folder, and look for the one with the right instance # and the right applicant's name.

Find Entry Activity configured as:  \LFForms\Fire Permits\Fire Permits Waiting\Fire Permit Application #%(FormsBPInstanceID) - %(RetrieveFirePermitApplicationVariables_Applicant_Name)

What I want to do is tell it to look for the instance number WITHIN the application document names that it finds in the target folder, but there is no way for me to tell it to look for just the number within the names.  Am I wrong, or is there a better way?  

0 0

Answer

SELECTED ANSWER
replied on November 22, 2017

Instead of a Find Entry activity, can you use a Search Repository activity.  You could search within the folder path of Fire Permits Waiting.  Plus search the entry name with a wild character (Fire Permit Application #%(FormsBPInstanceID) - *) so it will pick up the the document based on the BPInstanceID regardless of the name.

0 0
replied on November 22, 2017

Jennifer, this is exactly what I was hoping I could do... use the asterisks to tell it to just look for the number within the name of the documents it finds.  I thought about switching the Find Entry out for a Search Rep activity.  I'll have to give that a try.  Will report on any results, possibly tomorrow.

0 0

Replies

replied on November 22, 2017

I would recommend using the BP ID in combination with the Instance ID. If there is a chance the name could change, then you can't rely on that as a document name.

Instead, set the name as something like %(BP ID)-%(BP Instance ID) and rename it with the person's name when the entire process is complete.

It really depends on what is triggering your workflow, at what point(s) in the process it will run, and when you need to save the document to the repository.

 

However, it sounds like you might want to save, or at least replace it with a new copy, at the end of the process since something on the form might actually change.

Note that if the name changes, then I imagine that would change the name on the form itself too so the original version you saved would be inaccurate anyway.

1 0
replied on November 22, 2017

Thanks, Jason.  I could try it like you're showing up top.  I initially wanted the name in there in order to make sure it didn't grab the wrong one, but matching two numbers like that might be safe.  I do have the name changed on the application to match the approved permit further on in the WF.  In fact, finding the application is in order to rename, file, and link the approved permit to the application.

I will respond again with my progress after I've tried a few alternatives.  Thanks!

0 0
replied on November 24, 2017

Reporting in on results:  Success!  It is matching up to the application now without having to match to a name.  

I changed the Find Entry to a Search Repository activity.  Not really sure why, except that it seemed easier at the time.  I do wonder if there will be miss-matches in the future.  I liked the idea of it having to match to two things, in order to be sure it found the right one.  I will keep an eye on it for awhile to see.

Thanks, Jason and Jennifer!

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

Sign in to reply to this post.