Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics CRM (Archived)

Plugin not working after v9 update : MessageName "ConvertQuoteToSalesOrder"

Posted on by Microsoft Employee

Hi,

We have updated our DEV instance in v9. Almost all our plugins needed rework.

One of them simply does'nt work at all.

It's registered on the entity "salesorderdetail" / Create / Pre Operation

We need to catch the event of the conversion of a quote to a salesorder

 if (context.ParentContext != null && context.ParentContext.MessageName == "ConvertQuoteToSalesOrder" )
{...}

This event isn't catched anymore. I can only catch the create event of a salesorder. Then, no more information on the quote which is being converted in the plugin context.

 var DevisGuid = (Guid)context.ParentContext.InputParameters["QuoteId"];


How can i get the quote Guid ?

I need it to do an action on each quotedetail wich are beeing converted into salesorderdetail.

Thany you in advance.

*This post is locked for comments

  • Anas EL Profile Picture
    Anas EL 40 on at
    RE: Plugin not working after v9 update : MessageName "ConvertQuoteToSalesOrder"

    Hi,

    I want to activate my quote automatically via plugin on pre operation, how can I do that knowing that the WIN message comes after ConvertQuoteToSalesOrder message which is no longer supported ?

    thank you in advance

  • RaviKashyap Profile Picture
    RaviKashyap 55,410 on at
    RE: Plugin not working after v9 update : MessageName "ConvertQuoteToSalesOrder"

    Great!!!.

    Please mark the suggestion as verified if it helped you.

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Plugin not working after v9 update : MessageName "ConvertQuoteToSalesOrder"

    Thank you Ravi, i am now able to get the "salesorderid", then the "quoteid" that i needed.

  • Verified answer
    RaviKashyap Profile Picture
    RaviKashyap 55,410 on at
    RE: Plugin not working after v9 update : MessageName "ConvertQuoteToSalesOrder"

    I think then you should be able to get the quote details from sales order and perform you required logic.

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Plugin not working after v9 update : MessageName "ConvertQuoteToSalesOrder"

    Hi and thanks,

    ANAND WANI @Dynamics 365 Rocker

    I googled on "SetState" of "Quote". I found that it relies on the quote activation (activated/deactivated).

    In fact, i need to launch the plugin everytime a quote is converted to a salesorder.

    If i use the "SetState" event, the plugin will only trigger the first time the quote will be converted. It won't trigger for the second, third... time.

     

    In fact, this plugin is here to reorder the newly created "salesorderdetails".

    When converting a "quote", Dynamics CRM create the salesorderdetails in the order of the "sequencenumber" field.

    Another plugin update each salesorderdetail "importsequencenumber" field, for us to keep track of data.

    We are not executing this request outside. I wil try to trigger the plugin on "Create" of a "Salesorder"

  • Verified answer
    RaviKashyap Profile Picture
    RaviKashyap 55,410 on at
    RE: Plugin not working after v9 update : MessageName "ConvertQuoteToSalesOrder"

    Hi,

    When the quote is converted into Order, the field Quote (quoteid) is populated on order. So if you register your plugin on create of order and then check if quote id contains data then you can retrieve the details of quote.

    Is there any specific reason you are trying to catch "ConvertQuoteToSalesOrder". Are you executing this request from somewhere outside?

    Hope this helps.

  • Dynamics365 Rocker Profile Picture
    Dynamics365 Rocker 7,755 on at
    RE: Plugin not working after v9 update : MessageName "ConvertQuoteToSalesOrder"

    Use old assembly and change message as suggested by Anand.

  • Suggested answer
    crm development Profile Picture
    crm development 870 on at
    RE: Plugin not working after v9 update : MessageName "ConvertQuoteToSalesOrder"

    Hi,

    ConvertQuoteToSalesOrder message is not supported for a plugin. docs.microsoft.com/.../supported-messages-entities-plugin.

    Give a try for a plugin on SetState of Quote.

    Thanks,

    Anand

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Plugin not working after v9 update : MessageName "ConvertQuoteToSalesOrder"

    Thanks for your response,

    The plugin solution is in .Net 4.5.2

    The CRM is in version 1710 (9.0.2.2081)

    When i upgrade to .Net 4.6.2, i get an error :

    Unhandled Exception: 
    System.ServiceModel.FaultException`1[[Microsoft.Xrm.Sdk.OrganizationServiceFault, Microsoft.Xrm.Sdk,
    Version=9.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]:
    Cet assembly du plug-in utilise la version 4.6.2 de .NET Framework.
    Pour le moment, Microsoft Dynamics 365 requiert la version 4.5.2 de .NET Framework pour les assemblys du plug-in.
    Régénérez cet assembly à l’aide de la version 4.5.2 de .NET Framework, puis réessayez.

    in english:
    This plugin assembly uses 4.6.2 of .NET Framework.
    For the moment, Microsoft Dynamics 365 requires the 4.5.2 version of the .NET Framework for the plug-in assemblys.
    Regenerate this assembly the 4.5.2 version of the .NET Framework and retry.
    
    
  • Suggested answer
    Dynamics365 Rocker Profile Picture
    Dynamics365 Rocker 7,755 on at
    RE: Plugin not working after v9 update : MessageName "ConvertQuoteToSalesOrder"

    CRM 9.0 uses  .NET 4.6.2 framework. Had you build all your code in .NET 4.6.2 framework before update?

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,280 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,235 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans