locked
How to assign a task to a queue in plugin in crm 2011? RRS feed

  • Question

  • Hi All,

     

    I want to create a task, and assign it to queue through plug-in, can some body help me how to do it.

     

    Thanks and Regards

    Ravi

    Saturday, November 5, 2011 12:16 PM

Answers

  • Hi Ravi,

    you need to use queue item, it will be something like this

    QueueItem item = new QueueItem
                {
                    QueueId = new EntityReference(Queue.EntityLogicalName, _queueId),
                    ObjectId = new EntityReference(Letter.EntityLogicalName, _letterId)
                };

                // Create the queueitem on the server, which will associate
                // the letter with the queue.
                _queueItemId = _serviceProxy.Create(item);

    change the letterid with taskid.

    here is link to sample code

    http://www.resultondemand.nl/support/sdk/87c72e1e-3ea8-4c54-8eb2-e7fbc19ff629.htm

    I hope this helps.


    Amreek Singh Senior CRM Consultant CDC Praxa Sydney, Australia http://mscrmshop.blogspot.com http://crm2011usersettings.codeplex.com
    Saturday, November 5, 2011 1:00 PM