I’m trying to fetch all action center form tasks, loop through them and check the email of the user the task is assigned to. I have several form in my action center that are pending.
I’m trying to user Item.AssignedToUser to fetch the email information, but for some reason it is null, where as the rest of the values such as Item.Id, Item.status, Item.AssignedToUserId exist
Since it seems difficult to figure out why AssignedToUser is null, I believe I can work with an alternative solution. I can get the ID of the user by using item.AssignedToUserId, and use the api “/odata/Users(item.AssignedToUserId)” to fetch all information about the user.
Yep, That can be done. But obviously Get Form Tasks should work.
And I believe the activity will return a collection of tasks output, which is like one service call will get all the details. But with API we may need to do multiple calls which is not looking good.
I hope you are not using any preview version of the activities, right ?
@Simon_FuI guess you can get assigned user id only when you assign that task to a specific user id. Try assign that task to a specific user, use the below video. Then try to retrieve assigned user
This topic is already old, but for those who are wondering.
With the Get Form Tasks you only get a list of tasks according to your filtering. Each individual task only contains minimal information about the actual task. So several of the usually tags you can use with a TaskObject are still null.
If you want all the data of any specific task you have to use the Get Task Data activity (input is a TaskID, which you can get from the results of your Get Form Tasks activity). Then you can get all the information that is contained within the task, like the assigned user.