Plugin Throwing Error RRS feed

  • Question

  • I have registered a plug-in against an entity to run on create of the entity.

    When I create a record in the entity I get the following error message:

    Plugin: System.MissingMethodException: Constructor on type 'Evaluations.Plugin' not found

    Anyone know why I'm getting this at runtime as the plugin compiles fine?

    Tuesday, October 20, 2015 10:42 AM

All replies

  • post your plugin code.

    the plugin can compile fine, but if the code is not correct it can throw an exception, the two things (compilation and the execution) are not related

    My blog: www.crmanswers.net - CRM Theme Generator

    Tuesday, October 20, 2015 11:27 AM
  • Please post your plugin code.
    Tuesday, October 20, 2015 12:57 PM
  • When CRM attempts to instantiate a plugin, it will use one of 3 constructors, depending on whether the plugin registration step has a configuration string. For a plugin called SamplePlugin, the possible constructors are:

    public SamplePlugin()
    public SamplePlugin(string unsecure)
    public SamplePlugin(string unsecure, string secure)

    I expect you code is missing one or more of these constructors. If you never use configuration data, you can get away with only having the default (first listed) constructor, but I'd always include all 3 to be sure

    Microsoft CRM MVP - http://mscrmuk.blogspot.com/ http://www.excitation.co.uk

    Tuesday, October 20, 2015 1:16 PM