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

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Copying custom product fields to quote product / order product etc

(1) ShareShare
ReportReport
Posted on by

Hello I'm very new to CRM and I'm hoping this is a simple thing.  Thanks for reading and thank you in advance for any guidance.

We're running CRM online 2016 version 8.1 if that helps.  

I haven't been able to get Product description to display on the add product sub grid in opportunity or quote if entered manually it works which lead me to believe it was just a relationship thing.  

I also have a few custom fields in the product entity and the same sort of behavior, I can tell there is a pointer to the product record inside the quote product record but it would appear that I need to copy the data from the product record into the quote product fields to be able to get it to show up on the quote product form or the word templates.  

I checked the field types are the same and the mappings are displaying there but no joy on the data.  

I contacted support and after some testing and agreement that the fields weren't showing up I was told it was by design and to contact a partner.  

I'm hoping someone can help steer me in the right direction I'm not sure if it's the best solution but what I'd like is when the quote product record is created it's checked if it's and existing product or a write-in product and if existing it just copies the field data from the corresponding product record, if the user decided to edit the description or other fields from there that is currently ok.  

Can this be done with workflows or business rules on the entity? or is javascript the only way? I'd prefer if it acted on record creation but if it's on the action in the form I can work with that, I tried some script before but couldn't seem to access the quotedetails subgrid it seemed like it had a delayed on load and trying to create the handler from the main form on load was failing.  

I'd also be curious how to get all the sales person's user data attached to the quote record so I can map the xml fields in word to show their ph & email etc. 

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    Nithya Gopinath Profile Picture
    17,078 on at
  • Suggested answer
    Alagunellaikumar Profile Picture
    6,212 on at

    Hi

    Please refer the following URL.

    crm.fullscope.com/save-time-entering-data-into-crm-by-mapping-fields-between-records

  • Community Member Profile Picture
    on at

    Thank you for the responses, but as I mentioned the mappings appear to already be there the data just doesn't come with them.

    ProductQuoteProduct.PNGrelationship between Product & Quote Product product_quote_details

    ProductQuoteProduct.PNGrelationship screen

    ProductMappings.PNGmappings.

    Is there anything else I should be checking??

  • Suggested answer
    Alagunellaikumar Profile Picture
    6,212 on at

    Why don't you write the plugin for quote product. Register plugin "create" "quoteproduct" post operation

  • Community Member Profile Picture
    on at

    Thank you for the plugin suggestion but that is beyond my skill set at present.  Is there some way to do this with the out of box solution? 

  • Suggested answer
    Alagunellaikumar Profile Picture
    6,212 on at

    There is no way in OOB. If you wish let me know I will write a plugin code and share it to you

  • Community Member Profile Picture
    on at

    If that wouldn't be too much trouble I'd be happy to try and learn. Thank you.

  • Community Member Profile Picture
    on at

    So I decided to dive into the plugin creation route. The quotedetails entity has a lookup field "productid" pointing back to the product entity I want to copy fields from the product entity to the quotedetails is this the correct code

    //create reference to product

    EntityReference ProdRef = entity.Attributes["productId"] as EntityReference;  

    //get data from reference

    var ProdTemp = service.Retrieve(ProdRef.LogicalName, ProdRef.Id, new Microsoft.Xrm.Sdk.Query.ColumnSet(true));

    //assign value to existing entity

    entity.Attributes["description"] = ProdTemp.Attributes["description"];

    Thank you.

  • Community Member Profile Picture
    on at

    Hi. This seems to be exactly what I need! I'm not new to CRM, but I'm new to coding... Where would I have to implement this code for it to work? Thanks a lot!

  • Community Member Profile Picture
    on at

    This code is part of a plugin.  I ended up getting a trial copy of Visual Studio Pro and using the CRM SDK was able to create and activate a plugin in our environment.  msdn.microsoft.com/.../gg334724.aspx should help you with some of the basics.

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
SA-08121319-0 Profile Picture

SA-08121319-0 4

#1
Calum MacFarlane Profile Picture

Calum MacFarlane 4

#3
Alex Fun Wei Jie Profile Picture

Alex Fun Wei Jie 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans