web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Plugin not working after v9 update : MessageName "ConvertQuoteToSalesOrder"

(0) ShareShare
ReportReport
Posted on by

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

I have the same question (0)
  • Suggested answer
    Dynamics365 Rocker Profile Picture
    7,755 on at

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

  • Community Member Profile Picture
    on at

    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
    crm development Profile Picture
    870 on at

    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

  • Dynamics365 Rocker Profile Picture
    7,755 on at

    Use old assembly and change message as suggested by Anand.

  • Verified answer
    RaviKashyap Profile Picture
    55,410 Moderator on at

    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.

  • Community Member Profile Picture
    on at

    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
    55,410 Moderator on at

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

  • Community Member Profile Picture
    on at

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

  • RaviKashyap Profile Picture
    55,410 Moderator on at

    Great!!!.

    Please mark the suggestion as verified if it helped you.

  • Anas EL Profile Picture
    40 on at

    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

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Meet the Microsoft Dynamics 365 Contact Center Champions

We are thrilled to have these Champions in our Community!

Congratulations to the March Top 10 Community Leaders

These are the community rock stars!

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
AS-17030037-0 Profile Picture

AS-17030037-0 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans