locked
Deletion Of custom entity RRS feed

  • Question

  • Hi all,

        I have created a custom entities called  rimmelorders(for rimmel sales order) and rimmelitems(for rimmel products).i created nx1 relation for rimmelitems on rimmelorders.

    this i have done after upgrading to rollup 13.  

     

    my solution worked perfectly but later im not able to delete/publish/export/import rimmelitems.

    i can publish all other entities apart from rimmelitems.

     

    here goes my list of errors like export error ... delete relationship error

    Exporting it:

     

    <?xml version="1.0" ?>

    - <error xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">

      <displaytitle />

      <displaytext />

      <description>An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.</description>

      <file>Not available</file>

      <line>Not available</line>

      <details>Exception of type 'System.Web.HttpUnhandledException' was thrown.</details>

      <requesturl>http://crm-demo/Xxxx/_grid/cmds/dlg_exportcustomizations.aspx</requesturl>

      <pathAndQuery>/Xxxx/_grid/cmds/dlg_exportcustomizations.aspx</pathAndQuery>

      <source>XML</source>

      <stacktrace>[NullReferenceException: Object reference not set to an instance of an object.] at Microsoft.Crm.ObjectModel.OrganizationUIService.LabelLoaderAllLanguages.LoadMetadataLabel(Int32 entityType, String attributeName, ExecutionContext context) at Microsoft.Crm.ObjectModel.OrganizationUIService.LabelLoader.LoadCellLabel(Guid cellObjectId, String cellObjectColumnName, Int32 objectType, String attributeName, ExecutionContext context) at Microsoft.Crm.ObjectModel.OrganizationUIService.InsertFormLabels(IBusinessEntity entity, ILabelLoader labelLoader, ExecutionContext context) at Microsoft.Crm.ObjectModel.OrganizationUIService.RetrieveMultipleWithAllLanguages(EntityExpression entityExpression, ExecutionContext context) at Microsoft.Crm.Metadata.OrganizationUIHelper.RetrieveInProductionHelper(Int32 objectTypeCode, ExecutionContext context) at Microsoft.Crm.Tools.ImportExportPublish.FormXmlHandler.ExportItem(XmlDocument importDocument) at Microsoft.Crm.Tools.ImportExportPublish.ExportHandler.Export(XmlDocument XDoc) at Microsoft.Crm.Tools.ImportExportPublish.ExportHandler.Export(XmlDocument XDoc) at Microsoft.Crm.Tools.ImportExportPublish.RootExportHandler.RunExport(String[] ExportEntities, String[] ExportRoles, String[] ExportWorkflows, ExportMask Mask) at Microsoft.Crm.Tools.ImportExportPublish.ExportXml.RunExport(String[] ExportEntities, String[] ExportRoles, String[] ExportWorkflows, ExportMask Mask, XmlDocument& ExportDoc) at Microsoft.Crm.Tools.ImportExportPublish.ExportXml.RunExport(String xmlArgs, XmlDocument& ExportDoc) at Microsoft.Crm.WebServices.ExportXmlService.ExportCompressed(String entities, String embeddedFileName, ExecutionContext context) [TargetInvocationException: Exception has been thrown by the target of an invocation.] at Microsoft.Crm.Application.Utility.Util.RaiseXMLError(Exception exception) at Microsoft.Crm.Dialogs.ExportCustomizationsPage.ConfigureForm() at Microsoft.Crm.Application.Controls.AppUIPage.OnPreRender(EventArgs e) at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) [HttpUnhandledException: Exception of type 'System.Web.HttpUnhandledException' was thrown.] at System.Web.UI.Page.HandleError(Exception e) at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) at System.Web.UI.Page.ProcessRequest() at System.Web.UI.Page.ProcessRequestWithNoAssert(HttpContext context) at System.Web.UI.Page.ProcessRequest(HttpContext context) at ASP.xxxx__grid_cmds_dlg_exportcustomizations_aspx.ProcessRequest(HttpContext context) at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)</stacktrace>

      </error>

     

     

     

     

    Error On deleting the related entities either NX1 or 1XN  

     

    Event code: 3005

    Event message: An unhandled exception has occurred.

    Event time: 12/20/2010 2:54:41 PM

    Event time (UTC): 12/20/2010 9:24:41 AM

    Event ID: 6f146257f6454d09898b5f463cbaa927

    Event sequence: 69

    Event occurrence: 1

    Event detail code: 0

     

    Application information:

        Application domain: /LM/W3SVC/1/ROOT-1-129373106231938480

        Trust level: Full

        Application Virtual Path: /

        Application Path: c:\inetpub\wwwroot\

        Machine name: XXXXSS

     

    Process information:

        Process ID: 5340

        Process name: w3wp.exe

        Account name: NT AUTHORITY\NETWORK SERVICE

     

    Exception information:

        Exception type: TargetInvocationException

        Exception message: Exception has been thrown by the target of an invocation.

     

    Request information:

        Request URL: http://192.168.1.86/Xxxx/_Common/icon.aspx?objectTypeCode=10016&iconType=NavigationIcon&inProduction=1&cache=1

        Request path: /Xxxx/_Common/icon.aspx

        User host address: 192.168.1.86

        User: IICDEV\Administrator

        Is authenticated: True

        Authentication Type: Negotiate

        Thread account name: NT AUTHORITY\NETWORK SERVICE

     

    Thread information:

        Thread ID: 8

        Thread account name: NT AUTHORITY\NETWORK SERVICE

        Is impersonating: False

        Stack trace:    at System.RuntimeMethodHandle._InvokeMethodFast(Object target, Object[] arguments, SignatureStruct& sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner)

       at System.RuntimeMethodHandle.InvokeMethodFast(Object target, Object[] arguments, Signature sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner)

       at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, Boolean skipVisibilityChecks)

       at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)

       at System.Web.Services.Protocols.LogicalMethodInfo.Invoke(Object target, Object[] values)

       at Microsoft.Crm.Extensibility.InternalOperationPlugin.Execute(IPluginExecutionContext context)

       at Microsoft.Crm.Extensibility.PluginStep.Execute(PipelineExecutionContext context)

       at Microsoft.Crm.Extensibility.Pipeline.Execute(PipelineExecutionContext context)

       at Microsoft.Crm.Extensibility.MessageProcessor.Execute(PipelineExecutionContext context)

       at Microsoft.Crm.Extensibility.InternalMessageDispatcher.Execute(PipelineExecutionContext context)

       at Microsoft.Crm.Extensibility.ExternalMessageDispatcher.Execute(String messageName, Int32 primaryObjectTypeCode, Int32 secondaryObjectTypeCode, PropertyBag fields, CorrelationToken correlationToken, CallerOriginToken originToken, UserAuth userAuth, Guid callerId)

       at Microsoft.Crm.Sdk.RequestBase.Process(Int32 primaryObjectTypeCode, Int32 secondaryObjectTypeCode, CorrelationToken correlationToken, CallerOriginToken originToken, UserAuth userAuth, Guid callerId)

       at Microsoft.Crm.Sdk.RequestBase.Process(CorrelationToken correlationToken, CallerOriginToken originToken, UserAuth userAuth, Guid callerId)

       at Microsoft.Crm.Sdk.CrmServiceInternal.Execute(RequestBase request, CorrelationToken correlationToken, CallerOriginToken originToken, UserAuth userAuth, Guid callerId)

       at Microsoft.Crm.Sdk.InProcessCrmService.Execute(Object request)

       at Microsoft.Crm.Application.Platform.ServiceCommands.PlatformCommand.ExecuteInternal()

       at Microsoft.Crm.Application.Platform.ServiceCommands.RetrieveMultipleCommand.Execute()

       at Microsoft.Crm.Application.Platform.Customization.RetrieveInProductionOrganizationUIByOrgId(Guid organizationId, Int32 objectTypeCode)

       at Microsoft.Crm.Application.Pages.Common.Icon.GetIconBits(Int32 objectTypeCode, IconType iconType, Boolean inProduction)

       at Microsoft.Crm.Application.Pages.Common.Icon.ConfigurePage()

       at Microsoft.Crm.Application.Controls.AppUIPage.OnPreRender(EventArgs e)

       at System.Web.UI.Control.PreRenderRecursiveInternal()

       at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

     

     

    Custom event details:

     

    For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.

     

     


    Thanks & Regards Vijender Reddy
    Monday, December 20, 2010 12:35 PM

Answers

All replies

  • Hello, Vijender.

    Search engine is your best friend ;) You should try to use it some day.

    Search Request brought following KB


    Microsoft CRM Freelancer

    My blog (english)
    Мой блог (русскоязычный)
    Monday, December 20, 2010 1:07 PM
    Moderator
  • thanks andriy,

     

    search can help me getting......

     1. enabling the trace: tested and got the same result as event viewer

    2. deleting the referentials associated with the to and for entities,im done but no use,its not deleting yet.

    3.try setting the type of behavior to referential and publish and later delete,im done this but same ...

    4. try import,as said this is not possible for the current issue

    5.import associate entity and delete relation ships there,i checked but its not showing any related entities to the rimmelitems.....

     

    ..... and more over took the admin help to delete the relation ships at the back end but its throwing some more errors....

     

    its custom entitites so killed much time to rework with different names,forms,attributes....


    Thanks & Regards Vijender Reddy
    Tuesday, December 21, 2010 9:21 AM
  • Try to Export rimmelorder entity with all other related entities to it...now on importing just import the rimmelorder entity.now see all the relationships are created there or not.if not create them and publish.....hope it will work :-)
    Wednesday, December 22, 2010 6:26 AM
  • @Raidenneator

    Thanks, i can import rimmelorders but not its associated entity so called rimmelitems.

     

    fun is that i can see the rimmelorder realtionship with rimmelitem in crm,but on imported and if i open in notepad there is no such related entity exists there.(as explained in point no 5 above)

    second point u mentioned is create them and publish,  i test this also its a vain result.

     

    i didnt have much support here,so what i did is juss started from fresh(time waste approach)

    ny how thanks dude

    Wednesday, December 22, 2010 9:57 AM