Answered by:
Cannot change Lead owner in CRM 2011

Question
-
Hi,
I am trying to change Lead owner. I can see for a moment that the Lead owner is changed but then the page is refreshed and it changes back to orginal owner and I do not get a change to file the change before it changes back. I have installed rollup 15.
It is not a permission issue because I am logged in as administrator. There are no errors in evenlogs on application server and no errors on the Sql server.
any ideas?
Erró
Monday, November 25, 2013 11:29 PM
Answers
-
Hi,
In order to change record's owner we need to assign record to the user.
how you are trying to change it ?
Hope this helps. If you get answer of your question, please mark the response as an answer and vote as helpful !!!
Vikram Singh. !!! My Blog- Marked as answer by Erró Friday, November 29, 2013 10:38 AM
Monday, November 25, 2013 11:52 PM -
Please try this
var header = GenerateAuthenticationHeader();var userid = "5AB7EF25-BA14-E011-8EF1-001E902341EC";var recordid = "BD3D383D-0317-E011-8EF1-001E902341EC";var target = "TargetOwnedAccount";var xml = "" +"<?xml version=\"1.0\" encoding=\"utf-8\"?>" +"<soap:Envelope xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\">" +header +" <soap:Body>" +" <Execute xmlns=\"http://schemas.microsoft.com/crm/2007/WebServices\">" +" <Request xsi:type=\"AssignRequest\">" +" <Target xsi:type=\""+ target +"\">" +" <EntityId>"+ recordid +"</EntityId>" +" </Target>" +" <Assignee>" +" <PrincipalId xmlns=\"http://schemas.microsoft.com/crm/2006/CoreTypes\">"+ userid +"</PrincipalId>" +" <Type xmlns=\"http://schemas.microsoft.com/crm/2006/CoreTypes\">User</Type>" +" </Assignee>" +" </Request>" +" </Execute>" +" </soap:Body>" +"</soap:Envelope>" +"";var xmlHttpRequest = new ActiveXObject("Msxml2.XMLHTTP");xmlHttpRequest.Open("POST", "/mscrmservices/2007/CrmService.asmx", false);xmlHttpRequest.setRequestHeader("SOAPAction", "http://schemas.microsoft.com/crm/2007/WebServices/Execute");xmlHttpRequest.setRequestHeader("Content-Type", "text/xml; charset=utf-8");xmlHttpRequest.setRequestHeader("Content-Length", xml.length);xmlHttpRequest.send(xml);var resultXml = xmlHttpRequest.responseXML;
Source: http://social.microsoft.com/Forums/en-US/a804bbe9-512c-44a9-b5b1-90f16b44a8b2/execute-method-assign-request-javascript?forum=crmdevelopment
I hope this helps. If my response answered your question, please mark the response as an answer and also vote as helpful.
Mubasher Sharif
Check out my about.me profile!
http://mubashersharif.blogspot.com
Linked-In Profile
Follow me on Twitter!- Marked as answer by Erró Friday, November 29, 2013 10:38 AM
Tuesday, November 26, 2013 9:04 AM
All replies
-
Hi,
In order to change record's owner we need to assign record to the user.
how you are trying to change it ?
Hope this helps. If you get answer of your question, please mark the response as an answer and vote as helpful !!!
Vikram Singh. !!! My Blog- Marked as answer by Erró Friday, November 29, 2013 10:38 AM
Monday, November 25, 2013 11:52 PM -
Hi,
that is my problem I cannot assign record to a different user :) This happens when I am trying to assign a different user to it.
Erró
Tuesday, November 26, 2013 7:36 AM -
Might there be JavaScript programmed against the form OnSave event that is preventing the owner change?
Tuesday, November 26, 2013 8:01 AMModerator -
Please try this
var header = GenerateAuthenticationHeader();var userid = "5AB7EF25-BA14-E011-8EF1-001E902341EC";var recordid = "BD3D383D-0317-E011-8EF1-001E902341EC";var target = "TargetOwnedAccount";var xml = "" +"<?xml version=\"1.0\" encoding=\"utf-8\"?>" +"<soap:Envelope xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\">" +header +" <soap:Body>" +" <Execute xmlns=\"http://schemas.microsoft.com/crm/2007/WebServices\">" +" <Request xsi:type=\"AssignRequest\">" +" <Target xsi:type=\""+ target +"\">" +" <EntityId>"+ recordid +"</EntityId>" +" </Target>" +" <Assignee>" +" <PrincipalId xmlns=\"http://schemas.microsoft.com/crm/2006/CoreTypes\">"+ userid +"</PrincipalId>" +" <Type xmlns=\"http://schemas.microsoft.com/crm/2006/CoreTypes\">User</Type>" +" </Assignee>" +" </Request>" +" </Execute>" +" </soap:Body>" +"</soap:Envelope>" +"";var xmlHttpRequest = new ActiveXObject("Msxml2.XMLHTTP");xmlHttpRequest.Open("POST", "/mscrmservices/2007/CrmService.asmx", false);xmlHttpRequest.setRequestHeader("SOAPAction", "http://schemas.microsoft.com/crm/2007/WebServices/Execute");xmlHttpRequest.setRequestHeader("Content-Type", "text/xml; charset=utf-8");xmlHttpRequest.setRequestHeader("Content-Length", xml.length);xmlHttpRequest.send(xml);var resultXml = xmlHttpRequest.responseXML;
Source: http://social.microsoft.com/Forums/en-US/a804bbe9-512c-44a9-b5b1-90f16b44a8b2/execute-method-assign-request-javascript?forum=crmdevelopment
I hope this helps. If my response answered your question, please mark the response as an answer and also vote as helpful.
Mubasher Sharif
Check out my about.me profile!
http://mubashersharif.blogspot.com
Linked-In Profile
Follow me on Twitter!- Marked as answer by Erró Friday, November 29, 2013 10:38 AM
Tuesday, November 26, 2013 9:04 AM