getting real-time value of fields in triggered actions
Hi,
I have the problem in triggered actions, that the values of list items may be overwritten by user form in the timespan between triggering and executing the triggered action.
When the triggered action is executed it doesn't use the field values after the second user-change (via user form) but the first values. I tried to get the actual (real time) values in the triggered action by using queries. It seems that this sometimes work (load the actual values) and sometimes not.
Does anybody know a good and reliable routine to get the realtime values of element fields in triggered actions?
Best regards, Christoph
-
Hi Christoph.
Triggered actions are designed to execute all SharePoint List or Library item changes individually.
The base condition to start the Triggered action is the increased item version.
Let's say item versions were 1.0 -> 1.1 -> 2.0 -> 3.0, then the Triggered action will start and execute 3 times (1.0 -> 1.1; 1.1 -> 2.0 and 2.0 -> 3.0).
During these executions, field placeholders will return item values from the latest version in an execution pair.
For example, during execution between v. 1.0 to 1.1 field placeholders will return values from version 1.1 even it currently has v 3.0.
And it may be delayed between processing versions because of the delay between SharePoint events.
However query functions like:
[[@Functions.GetFirstValueForQuery....
[[@Functions.GetValuesForQuery...
[[@Functions.QueryList
Should get the latest value of the List/Library item during Triggered Actions executions doesn't matter what pair of item version it processes.
I can also suggest you also use an additional Condition action to check if item values have already been updated (by the user or by Triggered action, depending on your case) to skip not needed Triggered actions updates (for example you can use placeholders like [[Field.IsChanged]]).
You can also share more details about your case here, but in general, the described approaches should work for your case if I understand you correctly.
Best Regards
Vladyslav Noskov
0
Please sign in to leave a comment.
Comments
1 comment