Page 1 of 1
ExtPrice - sales order

Posted:
Wed Feb 27, 2019 5:56 pm
by Riyaz
Hi There
I’m trying to amend the sales lines item value through plugin, am changing salesexgst but it’s not making any effect in the calculations , looks like the value to change is ExtPrice, can you pls advise on how to change it via plugin
Re: ExtPrice - sales order 

Posted:
Thu Feb 28, 2019 10:10 am
by Scott.Pearce
You should try changing the line's .DiscountedPrice property - this is what is populated into the "ExtPrice" field.
Re: ExtPrice - sales order

Posted:
Fri Mar 01, 2019 11:27 am
by Riyaz
Thanks Scott
That worked fine, am also trying to set a tax rate as am updating the CartageCharge1 value, but it says its read only, have tried the below
salesOrderH.CartageCharge1.TaxRate.RecID
salesOrderH.CartageCharge1.TaxRate.Rate
Re: ExtPrice - sales order

Posted:
Fri Mar 01, 2019 12:07 pm
by Scott.Pearce
TaxRates are read, you do not set the individual properties.
- Code: Select all
string MyTaxID = "GST07000000000000000";
salesOrderH.CartageCharge1.TaxRate.ReadRecord(MyTaxID);
Re: ExtPrice - sales order

Posted:
Wed Mar 20, 2019 12:30 pm
by Riyaz
Hi Scott
Thanks that worked, but whats been happening is that, we have debtor price scheme enabled, and its overriding the price that the plugin sets, is there any way around it?
Re: ExtPrice - sales order

Posted:
Tue Mar 26, 2019 2:35 pm
by Mike.Sheen
Riyaz wrote:Hi Scott
Thanks that worked, but whats been happening is that, we have debtor price scheme enabled, and its overriding the price that the plugin sets, is there any way around it?
Are you saying the reading of the tax rate is changing the price?
If so, then just set the price to what you want after reading the tax rate in your code.