29
Feb
Assigning a (workflow)task to a Group from code can be tricky, but this trick works:
SPGroup group = SPWeb.UserGroups[“groupname”];SPFieldUserValue groupvalue = new SPFIeldUserValue( group.ParentWeb, group.ID, group.Name);SPWorkflowTaskProperties taskProperties = new SPWorkflowTaskProperties(); (Connect these taskproperties to the task to update)taskProperties.AssignedTo = groupvalue.LookupValue;
To display these tasks in the task list the view 'Groups' has to be selected. they will not shop up in the 'My Tasks' view.
Comments (0)
Tam Tam brengt je wereld online.