In an earlier post I explained how to create an entity from a Unified Service Desk agent script.
This essentially described the process needed to use the CRM_New_Page action to create an entity. In other examples I have triggered this action from an agent script and also from a toolbar.
I have recently created another example of this to create an opportunity from a contact.
In this my toolbar button looked like this ….
The action it called, that did all the work, looked like this …..
The data portion looked like this ….
LogicalName=opportunity customerid=EntityReference(contact,[[contact.Id]]) customeridname=[[contact.fullname]] parentcontactid=[[contact.Id]+] parentcontactidname=[[contact.fullname]+] parentaccountid=[[contact.parentcustomerid.Id]+] parentaccountidname=[[contact.parentcustomerid.name]+]
I also created another similar action to allow me to create an opportunity for an account. With that the data portion was change to look like this ….
LogicalName=opportunity customerid=EntityReference(account,[[account.Id]]) customeridname=[[account.name]] parentaccountid=[[account.Id]+] parentaccountidname=[[account.name]+] parentcontactid=[[account.primarycontactid.Id]+] parentcontactidname=[[account.primarycontactid.name]+]
Pingback: USD – Agent Scripts Collection | Microsoft Dynamics CRM and Unified Service Desk
Hi Neil,
I have created opportunity host control as it was not there in USD. then I have tried to run above code. still it does not work. when I used “incident” as host control in above action call and used data as “LogicalName=incident” then it worked.
Please let me know why this is happening?
Regards,
Vivek
LikeLike
Hi Vivek,
Firstly thanks for reading my blog and posting a comment.
Have you checked you window navigation rule? The most common reason for a tab not loading in this situation is a missing or incorrectly defined window navigation rule.
I am confident that the approach I have described works. Can you please check you navigation rules first?
If that isn’t the answer feel free to reply back with more details and also let me know you USD version?
Thanks again,
Neil.
LikeLike
Neil, Thanks a lot for great help. As you said I have to create a windows rule like “LoadOpportunityPage” and it worked.
Regards,
Vivek
LikeLike
Hi Neil,
As you said, windows rule was missing so I have to create a windows rule like “LoadOpportunityPage” which was quite similar to “LoadContactPage” in which I have to replace “contact” word with “Opportunity”.
Thanks a lot for a great help.
Regards,
Vivek
LikeLike
Pingback: USD – The Book | Microsoft Dynamics CRM and Unified Service Desk