Mattersphere Developers Forum
Would you like to react to this message? Create an account in a few clicks or log in to continue.

Go down
avatar
Admin
Admin
Posts : 122
Join date : 2018-12-17
https://mattersphere-devs.forumotion.com

Refresh Task List In Script Empty Refresh Task List In Script

Mon 27 Jan 2020 - 17:17
Hi, We have general tasks that on the click of a 'complete' button (assigned to the 'Service' action) run code as part of our workflow. We have our own message boxes popping up to conditionally add the next task. Because of this the 'Do you want to complete this task?” message box that automatically appears when this button is clicked gets in the way.
To get around this we have changed the action on the button to 'None', but then the task does not get completed automatically. So we set the task as complete in the code with:
Code:

tsk.SetExtraInfo("tskComplete", 1);
tsk.Completed = DateTime.Now;

int user = FWBS.OMS.User.GetUser(_legalAsst);
tsk.SetExtraInfo("tskCompletedBy", _legalAsst);
tsk.Update();

How do we refresh the task search list after this, to hide the task that we have just marked at complete? At the moment we have to manually click refresh. Thanks,
Romie
_____________________________________________________________________________________________________________________
Sorry ignore this post, we've just figured out the RefreshItem on the searchlist works.
Back to top
Permissions in this forum:
You cannot reply to topics in this forum