Skip to main content

In my workflow I allow the user assigned a task to change a field from within the task. This works correctly and the column is properly updated in SharePoint. A few steps later an email is sent out with information from that column. This isn't a set variable, but I go back to SharePoint_Item > MetaData > Items > Item and select the column.

 

In this email the data is the old, unchanged data, even though the SharePoint column is correct within SP itself.

 

Thinking perhaps the workflow was moving too quickly to grab the correct data I put a pause for 2 minutes on the workflow. This did not help.

 

I then wrote that SP column to a K2 Workflow variable and placed that variable in the email, but the variable actually has the old data.

 

It appears that K2 does not go back out to SharePoint to grab information once the workflow is rolling, but this doesn't make sense to me.

When is your workflow luanched (change/created)?  I'm confused on how you described these steps:

 

#1 This works correctly and the column is properly updated in SharePoint. A few steps later an email is sent out with information from that column.

 

# 2 In this email the data is the old, unchanged data.

 

Is there an initial email that is correct, then if they modify the data it sends out another email and it retains the first value loaded?

 

It sounds like a squence deal like something isn't being set in the correct order...but I would like to hear a bit more about the process.


Yes, you are correct as an initial email is sent at the start of the workflow and the information is correct from the data populated when the SharePoint item is created. The change to the SharePoint column comes from the K2 task and K2 correctly updates the information in SharePoint. Then K2 sends another email at the end of the workflow but the original data from the SharePoint column is included in the email, not the updated information. I’m including an image to better explain it.

 

13379iE8B3318DA5E8A4F1.png


12743iEBF85A9CB672AF2F.png

JArthur,


This is because the SharePoint_Item field is designed to give K2 SharePoint Context on process start. You will need to use SharePoint item event to update, retrieve, and etc. to manipulate your SharePoint list item. 


Hope this helps,


Gail


Reply