【问题标题】:Linking activities to an account in CRM 4.0将活动链接到 CRM 4.0 中的帐户
【发布时间】:2009-03-12 14:24:46
【问题描述】:

我正在使用 CRM 4.0 Web 服务界面开发应用程序,需要以编程方式创建电话记录并将其链接到帐户记录。我可以看到如何创建记录,但我不确定如何将电话链接到帐户。任何帮助将不胜感激。

谢谢

奈杰尔

【问题讨论】:

    标签: dynamics-crm dynamics-crm-4


    【解决方案1】:

    您不能将活动(如电话)直接链接到实体(如帐户)。您必须使用 activityparty 对象来执行此操作。
    要做到这一点,请按照以下步骤操作(我假设该帐户存在):

            phonecall newPhoneCall = new phonecall ();
    
            // Set the properties of the newPhoneCall.
            newPhoneCall.subject = "Test newPhoneCall";
            newPhoneCall.description = "New newPhoneCall";
    
            // Create the party sending and receiving the newPhoneCall.
            activityparty party = new activityparty();
    
            // Set the properties of Activityparty.
            party.partyid = new Lookup();
            party.partyid.type = EntityName.account.ToString();
            party.partyid.Value = existingAccount.accountId;
    
            // The party sends and receives the newPhoneCall.
            newPhoneCall.from = new activityparty[] { };
            newPhoneCall.to = new activityparty[] { party };
    

    然后照常创建电话活动。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2023-02-15
      • 2018-06-06
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多