cancel
Showing results for 
Search instead for 
Did you mean: 

how to programmatically transition a document from one queue to another

Jason_Muslin
Champ in-the-making
Champ in-the-making

Good Day to All!

I am in the process of creating a workflow and I am wondering, what is the syntax for moving a doc between queues? I have an If..Then..Statement and a select case statement I want to use but until I can figure out a way to move docs between queues, its kinda useless.

On that note, is there any documentation that would show what the OnBase Script Objects are and what their parameters are, etc...?

 

have a great day

9 REPLIES 9

William_Howell
Star Contributor
Star Contributor

I agree and never use a script when there are rules and actions to support what I need to do. Running a script to perform transitions makes it somewhat harder to understand document flow when troubleshooting or tracing. Also workflow is more or less self-documenting, but having to step through workflow code and toggle out to a script to figure out what it does makes it harder for the next guy walking in to pick up where you left off. And Workflow Studio will not pick up work performed in scripts so you have to create additional documentation and maintain it.

I choose to set property bag variables in scripts and then let Workflow rules determine how to route the document. 

Jason_Muslin
Champ in-the-making
Champ in-the-making

Interesting...So now my question is this:

how does one go about setting up and using property bag variables that the workflow can also use?

Seth_Yantiss
Star Collaborator
Star Collaborator

Jason,

I believe that the general path of the conversation toward a solution to your problem has been steered toward scripting it in VBScript in error.  Taking a guess here, that you're a programmer by trade and have taken over the workflow maintenance duties out of necessity with haste.

So, if this is accurate, let's start back from the top;

1. The user imports a document and adds keywords.  Is the imported document type set to automatically add the document to a LifeCycle?  If so then the first queue it enters should be a system queue with no user access where "System Work" rules and actions would move the document to one of your six working queues.  (Preferably this work would be done by a timer, but that's part of a different discussion)

Routing of documents by keyword values is accomplished by the use of a pair of Rules and Actions.  Go to your initial queue and add a rule (CTRL+R when the System Work icon is selected).  Set the rule to "KEY - Check Keyword Value on This Document".  Select the appropriate keyword and value, and under the True response for the Rule, make a new action (CTRL-A).  This action should be "DOC - Transition This Document", where you will set the desired destination queue.

You can set a new rule to check for the next keyword value under the False register for the first Action, or create a new Rule under the System Work header.  It is not recommended to nest more than 6 Rules.

Each Rule and Action will need to have a different name.  Same named Rules/Actions are considered to be the same object and a change to the object will change all instances of that object.

2. The user fills out a form.  Is this form an electronic form in OnBase?  If so, there is an action to create an electronic form for a document that allows the creation of an HTML based form that can inherit the keywords from the originating document.  Or another Action that can auto generate a form with three keyword fields for data entry.  Once completed, the HTML form can be referenced by Rules/Actions that have "Related Document" in the Rule/Action.

Whatever the case, when the user launches the Ad Hoc task, the last item in the task should be an Action of "DOC - Transition This Document" where you set the destination for the "Completed" queue.

I think you'd benefit greatly from the light reading in the SYSADMIN Modular Reference Guide.  I'm not including a link as my iPad is not conducive to such things.

Oh...  Yes it is.  

https://www.hyland.com/community/onbase_product_communities/m/mrg12/11164.aspx

Cheers,

Seth

Jason_Muslin
Champ in-the-making
Champ in-the-making

Thanks for all of the replies but Seth, you're awesome and you hit the nail right on the head! Yes, I am a programmer by trade and yes, I have been thrown into the fire with this workflow. I have been disecting the html code, the VBScript and the worklflow for several days and while the workflow works, it has some serious inefficiencies both on the user side and the workflow side. I have actually scheduled a meeting with the users to determine not only how it should work but how they want it to work. Baby steps...

 

more to come...

Jason

Seth_Yantiss
Star Collaborator
Star Collaborator

Jason,

No problem!  Baby steps is probably the right approach.  🙂 

One little bit of advise, go through all of the rules and actions that you have at your disposal (version specific) and know your tools inventory as you're walking through their workflow desires with them.  This will make it easier for you to envision the solution as they are telling you their desires.

Cheers,
Seth