English version
German version
Spanish version
French version
Italian version
Portuguese / Brazilian version
Dutch version
Greek version
Russian version
Japanese version
Korean version
Simplified Chinese version
Traditional Chinese version
Hindi version
Czech version
Slovak version
Bulgarian version
 

微软CRM定制?编程封闭电子邮件活动

软件 RSS Feed





Microsoft CRM是CRM来自微软和试图获得来自Siebel,甲骨文等公司的市场份额,传统的客户关系管理系统供应商的答案。微软CRM使用微软的所有频谱 最新技术:。净,硕士交易所的MS Outlook,MS SQL Server的,复制,索引,活动目录,Windows 2000/2003安全模型,C#中,VB.Net,HTML和XML Web服务,XLTP中,Javascript等等。今天的 主题的电子邮件的类型节目活性的这些自定义-你通常处理当您的Microsoft Exchange客户关系管理,改善连接。你如何建立封闭的活动-这是主要的讨论话题。我们将 使用C#。对我们的外汇事件处理程序中的作用净codingOne /接收器是微软的CRM创造处理传入和传出的电子邮件信息公开活动。与微软的CRM交互使用两个接触?使用 微软的CRM的SDK(入站和出站处理XML消息),并通过直接访问微软的CRM数据库。让我们先看一看封闭活动创造算法:1。首先,我们需要了解的实体,我们需要创建 活动为:帐户,铅或联系人。选择应使用的具体标准是什么?在我们的案例,这是电子邮件地址:如果((crmAccount = crmConnector.GetAccount(mailboxFrom))!=空)()否则如果((crmContact = crmConnector.GetContact(mailboxFrom))!=空)()否则如果((crmLead = crmConnector.GetLead(mailboxFrom))!=空)()2。然后,我们必须得到的GUID的MS CRM用户,谁拥有这个实体,ç#是这样的:crmUser =代码 crmConnector.GetUser(crmAccount.GetOwnerId()); 3。下一步是建立封闭的活动:emailId = crmConnector.CreateEmailActivity(crmUser.GetId(),Microsoft.Crm.Platform.Types.ObjectType.otAccount, crmAccount.GetId(),Microsoft.Crm.Platform.Types.ObjectType.otSystemUser,crmUser.GetId(),crmAccount.GetEmailAddress(),crmUser.GetEmailAddress(),sSubject,sBody); 4。该方法来创建封闭活动:市民的Guid CreateEmailActivity项(GUID用户标识,廉政fromObjectType中,GUID fromObjectId,廉政toObjectType中,GUID toObjectId,串mailFrom,串邮寄地址,字符串问题,字符串机构)(尝试电子邮件活动(log.Debug(“准备 创建");// BizUser代理objectMicrosoft.Crm.Platform.Proxy.BizUser bizUser =新Microsoft.Crm.Platform.Proxy.BizUser(); ICredentials证书=新NetworkCredential(sysUserId,sysPassword, sysDomain); bizUser.Url = crmDir +“BizUser.srf”; bizUser.Credentials =凭证; Microsoft.Crm.Platform.Proxy.CUserAuth userAuth = bizUser.WhoAmI ();// CRMEmail代理objectMicrosoft.Crm.Platform.Proxy。 CRMEmail电子邮件= 新Microsoft.Crm.Platform.Proxy.CRMEmail(); email.Credentials =凭证; email.Url = crmDir +“CRMEmail.srf”; / /设置为activitystring strActivityXml XML字符串=“”; strActivityXml + =“ “strActivityXml + = “”)+ "]]>"; strActivityXml + =“”; strActivityXml + = userId.ToString(“乙”)+“”; strActivityXml + = "";//设置为partiesstring活动的XML字符串strPartiesXml = “”; strPartiesXml + =“”; strPartiesXml + =“”+ 邮寄地址+“”,如果(toObjectType == Microsoft.Crm.Platform.Types.ObjectType.otSystemUser)(strPartiesXml + =“”+ Microsoft.Crm.Platform.Types.ObjectType.otSystemUser.ToString()+“”;)其他如果(toObjectType == Microsoft.Crm.Platform.Types.ObjectType.otAccount)(strPartiesXml + =“”+ Microsoft.Crm.Platform.Types.ObjectType.otAccount.ToString()+“”;)否则如果(toObjectType == Microsoft.Crm.Platform 。Types.ObjectType.otContact) (strPartiesXml + =“”+ Microsoft.Crm.Platform.Types.ObjectType.otContact.ToString()+“”;)否则如果(toObjectType == Microsoft.Crm.Platform.Types.ObjectType.otLead)(strPartiesXml + =“ “+ Microsoft.Crm.Platform.Types.ObjectType.otLead.ToString()+“”;)strPartiesXml + ='“+ toObjectId.ToString(”乙“)+”“; strPartiesXml + =”“; strPartiesXml + = Microsoft.Crm.Platform.Types.ACTIVITY_PARTY_TYPE.ACTIVITY_PARTY_TO_RECIPIENT.ToString(); strPartiesXml + =“”; strPartiesXml + =“”; strPartiesXml + =“”; strPartiesXml + =“”+ mailFrom +“”,如果(fromObjectType == Microsoft.Crm.Platform.Types.ObjectType.otSystemUser)(strPartiesXml + =“”+ Microsoft.Crm.Platform.Types.ObjectType.otSystemUser.ToString()+“”;)否则如果(fromObjectType == Microsoft.Crm.Platform.Types.ObjectType.otAccount)(strPartiesXml + =“”+ Microsoft.Crm.Platform.Types.ObjectType.otAccount.ToString()+“”;)否则如果(fromObjectType == Microsoft.Crm.Platform 。Types.ObjectType.otContact) (strPartiesXml + =“”+ Microsoft.Crm.Platform.Types.ObjectType.otContact.ToString()+“”;)否则如果(fromObjectType == Microsoft.Crm.Platform.Types.ObjectType.otLead)(strPartiesXml + =“ “+ Microsoft.Crm.Platform.Types.ObjectType.otLead.ToString()+“”;)strPartiesXml + ='“+ fromObjectId.ToString(”乙“)+”“; strPartiesXml + =”“; strPartiesXml + = Microsoft.Crm.Platform.Types.ACTIVITY_PARTY_TYPE.ACTIVITY_PARTY_SENDER.ToString(); strPartiesXml + =“”; strPartiesXml + =“”; strPartiesXml + =“”; log.Debug(strPartiesXml); / /创建电子邮件objectGuid的emailId =新 的GUID(email.Create(userAuth,strActivityXml,strPartiesXml));返回emailId;)赶上(System.Web.Services.Protocols.SoapException五)(log.Debug(“出错提示:”+ e.Message +“”+大肠杆菌Detail.OuterXml +“源:”+ e.Source);)捕获(异常五)(log.Debug(e.Message +“”+ e.StackTrace);)返回新的GUID();)5。为了使刚刚建立正确显示,你需要安装它的根据微软的CRM标准标志的活动:市民 无效UpdateActivityCodes项(GUID emailId)(尝试(OleDbCommand的命令= conn.CreateCommand(); command.CommandText =“更新ActivityBase系列DirectionCode =(?),StateCode =(?),PriorityCode =(?)凡ActivityId = (?)"; command.Prepare()command.Parameters.Add(新OleDbParameter(“DirectionCode”,Microsoft.Crm.Platform.Types.EVENT_DIRECTION.ED_INCOMING)); command.Parameters.Add(新OleDbParameter(“StateCode” , Microsoft.Crm.Platform.Types.ACTIVITY_STATE.ACTS_CLOSED)); command.Parameters.Add(新OleDbParameter(“PriorityCode”,Microsoft.Crm.Platform.Types.PRIORITY_CODE.PC_MEDIUM)); command.Parameters.Add(新 OleDbParameter(“ActivityId”,emailId)); log.Debug(“准备更新活动代码”+ emailId.ToString(“乙”)command.ExecuteNonQuery +“在ActivityBase”);();)捕获(异常五)( log.Debug(e.Message +“”+ e.StackTrace);))公共无效UpdateActivityQueueCodes项(GUID emailId中,GUID queueId)(尝试(OleDbCommand的命令= conn.CreateCommand(); command.CommandText =“更新QueueItemBase确定的优先=(?),国家=(?),QueueId = (?)其中的ObjectID = (?)"; command.Prepare()command.Parameters.Add(新OleDbParameter(“优先权”,Microsoft.Crm.Platform.Types.PRIORITY_CODE.PC_MEDIUM)); command.Parameters.Add(新OleDbParameter(“国家”, Microsoft.Crm.Platform.Types.ACTIVITY_STATE.ACTS_CLOSED)); command.Parameters.Add(新OleDbParameter(“QueueId”,queueId)); command.Parameters.Add(新OleDbParameter(“的ObjectID”,emailId));日志。调试(“准备更新 活动队列代码“+ emailId.ToString(”乙“)+”在QueueItemBase“); command.ExecuteNonQuery();)捕获(异常五)(log.Debug(e.Message +”“+ e.StackTrace);) )快乐定制,实施和修改!如果你想 我们做的工作-给我们打电话1-866-528-0577! help@albaspectrum.comAbout的AuthorBoris马库什金铅是软件开发人员在Alba频谱技术?美国全国微软CRM,微软大平原

文章来源: Messaggiamo.Com

Translation by Google Translator





Related:

» Seo Elite: New Seo Software!
» AntiSpywareBOT
» Reverse Mobile
» Error Nuker


网管得到HTML代码
加上这条到你的网站!

网站管理员提交你的文章
无须登记!填写好的表格和你的文章是在 Messaggiamo.Com 目录!

Add to Google RSS Feed See our mobile site See our desktop site Follow us on Twitter!

提交你的文章,以 Messaggiamo.Com 目录

分类


版权 2006-2011 Messaggiamo.Com - 网站地图 - Privacy - 网站管理员提交你的文章,以 Messaggiamo.Com 目录 [0.01]
Hosting by webhosting24.com
Dedicated servers sponsored by server24.eu