|
<%
'-----------------------------------------
'PRICES INCLUDING TAX
'-----------------------------------------
If ON_PricesIncTax = "y" then
If Application(LICENSENUMBER & "showtaxdisplay") = "y" then
%>
<% WriteString("ContentText_ExTax") %> |
<% WriteString("ContentText_IncTax") %> |
<% Else %>
<% WriteString("ContentText_Price") %> |
<% End if
Else
'-----------------------------------------
'PRICES EXCLUDING TAX
'-----------------------------------------
%>
<% WriteString("ContentText_Price") %> |
<% WriteString("ContentText_Tax") %>
(%) |
<% End if %>
<% WriteString("ContentText_Qty") %> |
<% WriteString("ContentText_Total") %> |
<% do while NOT objRecordSet.EOF %>
| <% =objRecordSet("IR_VersionName") %> |
| <% =objRecordSet("IR_VersionCode") %> |
<%
'-----------------------------------------
'PRICES INCLUDING TAX
'-----------------------------------------
If ON_PricesIncTax = "y" then
If Application(LICENSENUMBER & "showtaxdisplay") = "y" then
%>
<% =CUR_Symbol & " " & CurrencyDisplay(objRecordSet("IR_PricePerItem") - objRecordSet("IR_TaxPerItem"), 1, CUR_HasDecimals) %> |
<% =CUR_Symbol & " " & CurrencyDisplay(objRecordSet("IR_TaxPerItem"), 1, CUR_HasDecimals) %> |
<% Else %>
<% =CUR_Symbol & " " & CurrencyDisplay(objRecordSet("IR_PricePerItem"), 1, CUR_HasDecimals) %> |
<% End if %>
<% =objRecordSet("IR_Quantity") %> |
<% =CUR_Symbol & " " & CurrencyDisplay(objRecordSet("IR_PricePerItem") * objRecordSet("IR_Quantity"), 1, CUR_HasDecimals) %> |
<% Else
'-----------------------------------------
'PRICES EXCLUDING TAX
'-----------------------------------------
%>
<% =CUR_Symbol & " " & CurrencyDisplay(objRecordSet("IR_PricePerItem"), 1, CUR_HasDecimals) %> |
<% =objRecordSet("IR_TaxPerItem") * 100 %> |
<% =objRecordSet("IR_Quantity") %> |
<% =CUR_Symbol & " " & CurrencyDisplay((0.0001 + (objRecordSet("IR_PricePerItem") * objRecordSet("IR_Quantity") * (1 + objRecordSet("IR_TaxPerItem")))), 1, CUR_HasDecimals) %> |
<% End if %>
<%
'-----------------------------------------------
'CALCULATE TOTAL
'The total amount without tax is not stored -
'this is calculated from the invoice rows
'records as we cycle through them here.
'-----------------------------------------------
'-----------------------------------------
'PRICES INCLUDING TAX
'-----------------------------------------
If ON_PricesIncTax = "y" then
numRowPriceExTax = Round((objRecordSet("IR_Quantity") * (objRecordSet("IR_PricePerItem") - objRecordSet("IR_TaxPerItem"))) - 0.0001, 2)
numRowPriceIncTax = objRecordSet("IR_PricePerItem") * objRecordSet("IR_Quantity")
'Price of row inc tax (row = items x qty)
numTotalPriceExTax = numTotalPriceExTax + numRowPriceExTax
numTotalPriceIncTax = numTotalPriceIncTax + numRowPriceIncTax
'Running total of order price ex tax
Else
'-----------------------------------------
'PRICES EXCLUDING TAX
'-----------------------------------------
numRowPriceExTax = Round(objRecordSet("IR_PricePerItem") * objRecordSet("IR_Quantity") , 2)
numRowPriceIncTax = objRecordSet("IR_PricePerItem") * objRecordSet("IR_Quantity") * (1 + objRecordSet("IR_TaxPerItem"))
'Price of row ex tax (row = items x qty)
numTotalPriceExTax = numTotalPriceExTax + numRowPriceExTax
numTotalPriceIncTax = numTotalPriceIncTax + numRowPriceIncTax
'Running total of order price ex tax
End if
objRecordSet.movenext
loop
'-----------------------------------------
'FINAL TOTAL DEPENDS ON COUNTRY
'-----------------------------------------
If ON_TaxDue = 1 then
strOrderValueTotal = GetString("ContentText_TotalOrderValue") & " = " & CUR_Symbol & " " & CurrencyDisplay(numTotalPriceIncTax, 1, CUR_HasDecimals) & "