Skip to main content


 

Symptoms


Is there any way to access items from an Item Reference from a workflow in a Server Event (Code) activity? Specifically, I'm wondering if it's possible to access an Item Reference member by name in a similar manner as Data Fields are accessed:

(C_)
K2.ProcessInstance.DataFieldss"MyDataField"].Value
 

Diagnoses


No API call currently exists to deal directly with item references. Several approaches exist as a workaround to this.
 

Resolution

It is currently not possible to access an item reference via API. Several workarounds exist depending on the specific situation.

Saving item reference fields to data fields in the workflow, which then can be used in lieu of an item reference and are accessible via API call.

If the form responsible for creating the item reference saves data to an external source (smartbox, SQL, etc), we could also access the item reference by calling the SmO tied to the data source, and passing appropriate parameters to retrieve the needed data.




 
Be the first to reply!

Reply