Quote Line Discount % reverts to 0 when changing Qty - how to force it to remain unless specifically over-typed?

Try putting it in DspDocDiscount …?

That’s assuming you aren’t calling the GetUnitPriceDtl method to do the calculation for you.

It’s going over my head now to be honest.

From within Quote.ChangeExpSellingQty/Post-Processing/[MyText]

I can invoke BO Method ‘erp.Quote.GetDtlUnitPriceInfo’ but there are 3 parameters I need to set bindings for and I’m now in cconfused.com territory.

Also can I put it into DspDocDiscount?
I can’t see that as an option as it’s not a DB field

svc.GetDtlUnitPriceInfo(true,false,ref q);

This is what we use in the code I posted above, and I got it from doing a trace to see what was going on when I did the same thing in the client screen. q in this case is the QuoteDataSet.

It’s in the field list in the BPM, because those fields are based on the dataset rather than the db. I got it wrong from memory, though, it’s DocDspDiscount.

One thing that could be throwing you off is if you use price lists, and/or there are price breaks.

We don’t use price breaks or price lists, so GetDtlUnitPriceInfo doesn’t do anything in our setup. Those are some of the extra conditions that @dhewi mentioned that my simple solution didn’t account for.

Did anyone ever get to the bottom of this? I am trying to do something similar in the Configurator. I have had success manipulating the Discount % and then executing the method associated with it on Orders… but when I take a similar approach in the QuoteDtl, I can’t get the % to change from whatever it thinks it should be based on Price List/Customer. 99% of the time that’s perfect. But we have one exception where we want to apply an incentive to bundle a certain part with a kit and in doing so, will apply additional % discount from what it would normally be.

I’ve tried setting the % field, executing the GetDtlUnitPriceInfo method, and then Update method. It’s as though I’ve done nothing at all. Just leaves it to whatever the default is based on ProdCode. Any advice at this point?