private Guid CreateLead(IOrganizationService _service)
    {
        Entity Lead = new Entity("lead");
        Lead.Attributes["Topic"] = "************";
        Lead.Attributes["FirstName"] = "*";
        Lead.Attributes["LastName"] = "*****"
        Lead.Attributes["CompanyName"] = "****"
        Lead.Attributes["Email"] = "****"
        Guid id = _service.Create(Lead);


Error message

'Leadaccount.CreateLead(Microsoft.Xrm.Sdk.IOrganizationService)': not all code paths return a value

Q

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.