Hello,
i work with CRM dynamics 365, i have an error when i want to delete attachement from email in draft status, also i can't delete the email contains attachement
i tried to delete the email with c# code in debug and i have the same error
this is the trace :
>Crm Exception: Message: An unexpected error occurred., ErrorCode: -2147220970, InnerException: System.NullReferenceException: La référence d'objet n'est pas définie à une instance d'un objet. à Microsoft.Crm.ObjectModel.ActivityMimeAttachmentService.DeleteInternal(BusinessEntityMoniker moniker, ExecutionContext context, Boolean updateEmailAttachmentCount) à Microsoft.Crm.ObjectModel.ActivityMimeAttachmentService.DeleteAssociatedAMAttachments(BusinessEntityMoniker moniker, Int32 objectTypeCode, ExecutionContext context) à Microsoft.Crm.Common.ObjectModel.EmailService.Delete(BusinessEntityMoniker moniker, ExecutionContext context) [2017-06-13 09:25:24.188] Process: w3wp |Organization:85b57212-bfb8-449a-9050-fb65e7e37bef |Thread: 40 |Category: Platform |User: 51947b1f-4a5d-e611-80c4-d4bed9b10258 |Level: Error |ReqId: 8019d410-9e40-4f27-bcbb-2eb43344e1c0 |ActivityId: 6d31c0de-d4f2-4d7d-a2ee-3666d0c28a03 | MessageProcessor.Execute ilOffset = 0x218 >MessageProcessor fail to process message 'Delete' for 'email'. [2017-06-13 09:25:24.188] Process: w3wp |Organization:00000000-0000-0000-0000-000000000000 |Thread: 40 |Category: Platform |User: 00000000-0000-0000-0000-000000000000 |Level: Error |ReqId: 8019d410-9e40-4f27-bcbb-2eb43344e1c0 |ActivityId: 6d31c0de-d4f2-4d7d-a2ee-3666d0c28a03 | ExceptionConverter.ToSingleFaultOther ilOffset = 0x30 >System.NullReferenceException: Microsoft Dynamics CRM has experienced an error. Reference number for administrators or support: #79C2C5DB: System.NullReferenceException: La référence d'objet n'est pas définie à une instance d'un objet. à Microsoft.Crm.ObjectModel.ActivityMimeAttachmentService.DeleteInternal(BusinessEntityMoniker moniker, ExecutionContext context, Boolean updateEmailAttachmentCount) à Microsoft.Crm.ObjectModel.ActivityMimeAttachmentService.DeleteAssociatedAMAttachments(BusinessEntityMoniker moniker, Int32 objectTypeCode, ExecutionContext context) à Microsoft.Crm.Common.ObjectModel.EmailService.Delete(BusinessEntityMoniker moniker, ExecutionContext context) [2017-06-13 09:25:42.658] Process: w3wp |Organization:85b57212-bfb8-449a-9050-fb65e7e37bef |Thread: 65 |Category: Platform.Sdk |User: 51947b1f-4a5d-e611-80c4-d4bed9b10258 |Level: Error |ReqId: daefea23-0a66-4cc5-a21b-829a61ceefc2 |ActivityId: daefea23-0a66-4cc5-a21b-829a61ceefc2 | VersionedPluginProxyStepBase.Execute ilOffset = 0x64 >Web Service Plug-in failed in SdkMessageProcessingStepId: {89CABB1B-EA3E-DB11-86A7-000A3A5473E8}; EntityName: email; Stage: 30; MessageName: Delete; AssemblyName: Microsoft.Crm.Extensibility.InternalOperationPlugin, Microsoft.Crm.ObjectModel, Version=8.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35; ClassName: Microsoft.Crm.Extensibility.InternalOperationPlugin; Exception: Unhandled Exception: System.Reflection.TargetInvocationException: Une exception a été levée par la cible d'un appel. à System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor) à System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments) à System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) à System.Web.Services.Protocols.LogicalMethodInfo.Invoke(Object target, Object[] values) à Microsoft.Crm.Extensibility.InternalOperationPlugin.Execute(IServiceProvider serviceProvider) à Microsoft.Crm.Extensibility.V5PluginProxyStep.ExecuteInternal(PipelineExecutionContext context) à Microsoft.Crm.Extensibility.VersionedPluginProxyStepBase.Execute(PipelineExecutionContext context) Inner Exception: System.NullReferenceException: La référence d'objet n'est pas définie à une instance d'un objet. à Microsoft.Crm.ObjectModel.ActivityMimeAttachmentService.DeleteInternal(BusinessEntityMoniker moniker, ExecutionContext context, Boolean updateEmailAttachmentCount) à Microsoft.Crm.ObjectModel.ActivityMimeAttachmentService.DeleteAssociatedAMAttachments(BusinessEntityMoniker moniker, Int32 objectTypeCode, ExecutionContext context) à Microsoft.Crm.Common.ObjectModel.EmailService.Delete(BusinessEntityMoniker moniker, ExecutionContext context)
*This post is locked for comments