Adding custom code

  • 24 August 2015
  • 1 reply
  • 5 views

Badge +1

Hi,

 

In my workflow, I have a smart object event which calls a read method, loads the smart object and update data fields.

 

Now I want to update certain data fields based on some conditions. How can I achieve that. I want to check some properties of smart object for certain values and update some data fields. I tried adding a code reference event/server event. With server event I am not able to access the smart object. How can I achieve this.

 

Thanks


1 reply

Badge +4

Hi HariWells,

I don't think custom code is needed for this.

In your activity where you want to set th eprocess datafields, simply swing a Data Event.

In your data event you map your destination(Which will be your datafield), next, and here comes something I really love about the K2 designer, in the Source box you drop the SMO Method you are calling it will auto matically resolve the inputs and outputs for your SMO then you just add the values and boom, on this stage I prefer to only let it retrieve the first item, depending on how the data source is structured.

Regards
Pieter

Reply