Showing results for 
Search instead for 
Did you mean: 

Problem with Linetotal 0 or discount 100 in a PO

Active Contributor
0 Kudos

Hello all,

I have a problem when I integrate Sales Order from R3 to Purchase Order in B1.

I use R3SO2B1PO.

Everything works perfect except when I want to put the line total with 0 value.

Depending in a condition I want to put the LineTotal with 0 or the line discount with 100%.

When I do this in the documents lines:

<xsl:if test="PSTYV=&apos;TANN&apos;">



I get this message: XCE001 Nested exception: BPE001 Nested exception: XCE001 Nested exception: XCE001 Nested exception: java.lang.RuntimeException: Invoke of: ReadXml Source: Description: Property 'DiscPrcnt' of 'DocumentLine' is invalid

When I do this:

<xsl:if test="PSTYV=&apos;TANN&apos;">



In B1 the line is not getting to 0 but I don't get any error.

In B1 the local currency is in DKK and the document is in EUR.

Please advise me what to do.

Thank you in advance.

Best regards,

Augusto Silva

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Augusto

I'd suggest that you install SAP Business One SDK and check diapi.chm file from 'Help" folder in case of such problems. It will give the actual name of the property not a name of the field from database - they differ much.


Public Property DiscountPercent() As Double

so use DiscountPercent


use UnitPrice = 0 or PriceAfterVAT = 0 instead of LineTotal

Hope this helps.

Kind regards,


Active Contributor
0 Kudos

Hi Radoslaw,

You were right. 🙂

I was using the name field of table and I should use the DiscountPercent.

Thank you for your help.

Best regards,


Answers (0)