Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Customer experience | Sales, Customer Insights,...
Answered

Got "Exception retrieving custom activity info - Exception has been thrown by the target of an invocation" error when Registering a Custom Workflow

(1) ShareShare
ReportReport
Posted on by 137

I am using CRM on-premise,  I have no problem to register a new plugin, but I got this error when I registering a  new custom Work flow.

"Exception retrieving custom activity info - Exception has been thrown by the target of an invocation"

I selected Isolation mode to "Sandbox", and Specify location to "Database",

Does anybody know what is wrong with my Registration process?

  • Verified answer
    Abanoub_Techtrack Profile Picture
    49 on at
    Got "Exception retrieving custom activity info - Exception has been thrown by the target of an invocation" error when Registering a Custom Workflow
    Hi Peter Could you please declare ur on prem version
  • Suggested answer
    Peter Cong Profile Picture
    137 on at
    RE: Got "Exception retrieving custom activity info - Exception has been thrown by the target of an invocation" error when Registering a Custom Workflow
    [quote user="Peter Cong"]

    I am using CRM on-premise,  I have no problem to register a new plugin, but I got this error when I registering a  new custom Work flow.

    "Exception retrieving custom activity info - Exception has been thrown by the target of an invocation"

    I selected Isolation mode to "Sandbox", and Specify location to "Database",

    Does anybody know what is wrong with my Registration process?

    [/quote]

    Thanks a lot for all help, this issue is resolved. the issue was caused by the version of .NET framework selected to create Custom workflow activity was using the high version number: 4.8, instead, I have to choose 4.5.2 version to match the current on-premise version my company is using. And the associated reference files Microsoft.workflow must choose lower version number (7.xxx), Not 9.0 version to make it compatible.

  • Verified answer
    sdfasdf Profile Picture
    840 on at
    RE: Got "Exception retrieving custom activity info - Exception has been thrown by the target of an invocation" error when Registering a Custom Workflow

    Hello,

    I would encourage you to collect platform traces while experimenting this issue to review the call stack. To enable tracing, please refer to this article: support.microsoft.com/.../how-to-enable-tracing-in-microsoft-dynamics-crm

    Once you get the platform traces, you can correlate the error message you got in Plugin Registration Tool via ActivityId and the time stamp. That should point you in the right direction to fix the issue.

  • Peter Cong Profile Picture
    137 on at
    RE: Got "Exception retrieving custom activity info - Exception has been thrown by the target of an invocation" error when Registering a Custom Workflow

    can anybody help please? thanks

  • Peter Cong Profile Picture
    137 on at
    RE: Got "Exception retrieving custom activity info - Exception has been thrown by the target of an invocation" error when Registering a Custom Workflow

    Hi Bipin, thanks a lot for your help,

    I had checked that, there is not other assemblies with same name. The error occurred when registering a custom workflow at the beginning first time. not sure how to check reference. I have no issue to register a new plug in.

  • Suggested answer
    Bipin D365 Profile Picture
    28,981 Moderator on at
    RE: Got "Exception retrieving custom activity info - Exception has been thrown by the target of an invocation" error when Registering a Custom Workflow

    Hi,

    Check below points.

    Make sure other assemblies doesn’t have the same name

    Sometime, Assembly which u tried to register get failed but the reference will be there. Unregister the reference and try again.

    Still, Try changing the major version of the assembly and register

    bidynamics365.com/

    Please mark my answer verified if i were helpful

  • Peter Cong Profile Picture
    137 on at
    RE: Got "Exception retrieving custom activity info - Exception has been thrown by the target of an invocation" error when Registering a Custom Workflow

    here is the details error message:

    Unhandled Exception: System.ServiceModel.FaultException`1[[Microsoft.Xrm.Sdk.OrganizationServiceFault, Microsoft.Xrm.Sdk, Version=9.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]: Exception retrieving custom activity info - Exception has been thrown by the target of an invocation.

    Detail: <OrganizationServiceFault xmlns="schemas.microsoft.com/.../Contracts" xmlns:i="www.w3.org/.../XMLSchema-instance">

     <ActivityId>77be9dbf-0c0c-41aa-a0ea-1f0cbfc886a5</ActivityId>

     <ErrorCode>-2147200995</ErrorCode>

     <ErrorDetails xmlns:a="schemas.datacontract.org/.../System.Collections.Generic" />

     <HelpLink i:nil="true" />

     <Message>Exception retrieving custom activity info - Exception has been thrown by the target of an invocation.</Message>

     <Timestamp>2020-09-23T19:27:06.1668068Z</Timestamp>

     <ExceptionRetriable>false</ExceptionRetriable>

     <ExceptionSource i:nil="true" />

     <InnerFault>

       <ActivityId>77be9dbf-0c0c-41aa-a0ea-1f0cbfc886a5</ActivityId>

       <ErrorCode>-2147200995</ErrorCode>

       <ErrorDetails xmlns:a="schemas.datacontract.org/.../System.Collections.Generic" />

       <HelpLink i:nil="true" />

       <Message>Exception retrieving custom activity info - Exception has been thrown by the target of an invocation.</Message>

       <Timestamp>2020-09-23T19:27:06.1668068Z</Timestamp>

       <ExceptionRetriable>false</ExceptionRetriable>

       <ExceptionSource i:nil="true" />

       <InnerFault i:nil="true" />

       <OriginalException i:nil="true" />

       <TraceText i:nil="true" />

     </InnerFault>

     <OriginalException i:nil="true" />

     <TraceText i:nil="true" />

    </OrganizationServiceFault>

    Server stack trace:

      at System.ServiceModel.Channels.ServiceChannel.HandleReply(ProxyOperationRuntime operation, ProxyRpc& rpc)

      at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean oneway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan timeout)

      at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage methodCall, ProxyOperationRuntime operation)

      at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message)

    Exception rethrown at [0]:

      at Microsoft.Crm.Tools.Libraries.RegistrationHelper.RegisterPlugin(CrmOrganization org, CrmPlugin plugin)

      at Microsoft.Crm.Tools.AssemblyRegistration.PluginRegistrationViewModel.btnregisterClick()

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

🌸 Community Spring Festival 2025 Challenge Winners! 🌸

Congratulations to all our community participants!

Adis Hodzic – Community Spotlight

We are honored to recognize Adis Hodzic as our May 2025 Community…

Kudos to the April Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard > Customer experience | Sales, Customer Insights, CRM

#1
Daivat Vartak (v-9davar) Profile Picture

Daivat Vartak (v-9d... 225 Super User 2025 Season 1

#2
Muhammad Shahzad Shafique Profile Picture

Muhammad Shahzad Sh... 106

#3
Vahid Ghafarpour Profile Picture

Vahid Ghafarpour 82 Super User 2025 Season 1

Overall leaderboard

Product updates

Dynamics 365 release plans