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)

Line Item Discount by Percentage for Quotes

(1) ShareShare
ReportReport
Posted on by 57
It seems the default for discounting in quotes is fixed dollar amount versus percent discount... I really don't understand this as Microsoft is trying to compete with SF.com and the others who all allow percent discount by line by default. When we resell products, it is all based on discount percentages... not dollar amounts... I am not even sure what kind of business would work that way but certainly not integrators, VARS, and resellers. Worse... it doesn't seem there is an easy way to fix this. Any ideas?

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    jlattimer Profile Picture
    24,562 on at

    Here is an idea (it make need a little effort to make it fully work) - *Note this won't work with the editable product grid functionality

    On your line item records, create a new decimal field (allows 0 -100) for the line's discount percent.

    Add it to the form, make the existing Manual Discount field read-only but keep it on the form.

    Add some JavaScript on the OnChange event of the new Discount Percent field to figure discount amount automatically and place the result in the manual discount field. Once the record it saved the built in calculations should still work as expected.

    JavaScript would be similar to this:

    function DiscountPercent_OnChange() {
        var discPer = Xrm.Page.getAttribute("new_discountpercent").getValue();
    	if (discPer === null || discPer === undefined) {
    		Xrm.Page.getAttribute("manualdiscountamount").setValue(0);
    	}
    	else {
    		var manDisc = (Xrm.Page.getAttribute("priceperunit").getValue() * Xrm.Page.getAttribute("quantity").getValue()) *
    			(discPer / 100);
    		Xrm.Page.getAttribute("manualdiscountamount").setValue(manDisc);
    	}
    	Xrm.Page.getAttribute("manualdiscountamount").setSubmitMode("always");
    }
    
  • Zazen Profile Picture
    185 on at

    Works like a treat ...thanks. Shame about the product grid functionality

  • Community Member Profile Picture
    on at

    This is great, thank you!

  • Fasil Muhammed Profile Picture
    55 on at

    Can you please help on below error for the same subject

    @192.168.0.11:5555/.../ClientApiWrapper.aspx line 157 > eval:1:1
    RunHandlerInternal@192.168.0.11:5555/.../ClientApiWrapper.aspx
    RunHandlers@192.168.0.11:5555/.../ClientApiWrapper.aspx
    OnScriptTagLoaded@192.168.0.11:5555/.../ClientApiWrapper.aspx
    AppendScriptTag/scriptTag.onload/<@192.168.0.11:5555/.../ClientApiWrapper.aspx

  • Ayadh Shakoor Profile Picture
    5 on at

    Hi Jason,

    which library do we need to add first before adding OnChange event?

    Thanks,

    Ayadh

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