Vertex Business Functions - Usage

wrohrbach

Member
Hi List,

We have an POS system external to OneWorld that we are receiving transaction information daily by way of a flat file. This flat file is then imported into OW through a table conversion which we then create journal entries for this data.

The final part of this process is to write the tax information back to Vertex. We are hoping to use the BSFNs already included in OneWorld, but we just can't seem to understand the flow of how they work together. Does anyone have any experience using the OneWorld BSFNs in a custom UBE to write tax information to the Vertex register? I'll outline how we think this works from examining the way that R42800 - Sales Update writes to Vertex.

1. Call B0000564 - Get Internal Next Number to get a job number for writing to cache

2. Call B4000050 - Load and Retrieve Vertex Cache with a '1' in cModeProcessing to load the cache (problem here seems to be that there is no input parameter for taxable amount. is this loaded into cache through another BSFN? B4201770 - LoadandRetrieveSalesVertexCache seems to be tied in here somewhere, but it appears to only be associated with adjustments to amounts already in the cache)

3. Call B4000050 - Load and Retrieve Vertex Cache again, this time with a '4' in cModeProcessing and a '1' in cWriteRegisterFlag to write what is in cache to the Vertex register

4. Call B4000050 - Load and Retrieve Vertex Cache a final time with a '3' in cModeProcessing to delete the information that is in the cache.

We have found other BSFNs that deal with Vertex that may or may not be the ones we want to use:

X00TAX - This seems to be THE main BSFN suite that does all the work writing to Vertex. I'm not sure if we should be calling some of its functions directly or allowing that to happen through the BSFNs referred to above.

B4001090 - Tax, Calculation for Sales and Purchasing: From what I can tell this function is used for retrieving tax information, not writing to Vertex.

B0000019 - Calculate Tax Authority Tax Amounts: Called from B4001090. Once again seems to be used for retrieving rather than writing.

There may be others that I am missing (if anyone knows of any, please let me know). Hopefully some of you out there have tried to do this in the past or have knowledge of the correct order in which to call these BSFNs (including parameters). Keep in mind that one of the issues we are having with this is that there is not an order number or invoice associated with these transaction, so we are hoping that we are not required to have a valid order/invoice number to use these BSFNs.

Sorry for the long post. If anyone has ANY information on the correct usage, please post here. I will be happy to supply more information (
wink.gif
) if needed.

Thanks In Advance,
Wade Rohrbach
Systems Analyst
Hartmann, Inc.
 
Hmmm..... Nobody has knowledge as to the correct usage of these business functions?
 
Here is the code you need with the Vertex Calls and parms. email me if you need more information. I'm calculating vertex tax in a few programs.

Note
VertexJobNumber is DD=JOBS
VertexErrorMessage is DD=MATH01


Enjoy...Rob
//
F4211.Select
VA rpt_WorkOrderNumber = TK Document (Order No, Invoice, etc.)
VA rpt_WorkOrderType = TK Order Type
VA rpt_IgnoreLineType != TK Line Type
PO szStatusCodeNext <= TK Status Code - Next
VA rpt_LinesAtZero != TK Units - Order/Transaction Quantity
VA rpt_LinesAtZero != TK Quantity Shipped
F4211.Fetch Next
RV Order Company <- TK Order Company (Order Number)
RV Order Number <- TK Document (Order No, Invoice, etc.)
RV Order Type <- TK Order Type
RV Line Number <- TK Line Number
RV Order Suffix <- TK Order Suffix
RV Business Unit <- TK Business Unit
RV Company <- TK Company
RV Address Number <- TK Address Number
RV Ship To <- TK Address Number - Ship To
RV Order Date <- TK Date - Order/Transaction
RV Invoice Date <- TK Date - Invoice
RV Item Number (Short) <- TK Item Number - Short
VA rpt_PartNumberLITM <- TK 2nd Item Number
VA rpt_DetailDSC1 <- TK Description
RV Line Type <- TK Line Type
RV Status Code - Next <- TK Status Code - Next
RV Header Business Unit <- TK Business Unit - Header
VA rpt_DetailUOM <- TK Unit of Measure as Input
RV Quantity <- TK Units - Order/Transaction Quantity
RV Quantity Shipped <- TK Quantity Shipped
VA rpt_DetailUnitPrice <- TK Amount - Price per Unit
RV Extended Price <- TK Amount - Extended Price
RV Payment Terms <- TK Payment Terms Code
RV Payment Instrument <- TK Payment Instrument
RV Sales Taxable <- TK Sales Taxable (Y/N)
RV Tax Rate/Area <- TK Tax Rate/Area
RV Tax Expl Code <- TK Tax Expl Code 1
While SV File_IO_Status is equal to CO SUCCESS
VA rpt_TaxesForLine = 0
VA rpt_ExtendedPriceTotalOrder = [VA rpt_ExtendedPriceTotalOrder]+[RV Extended Price]
If RV Tax Expl Code is not equal to "E"
And RV Sales Taxable is not equal to "N"
And RV Extended Price is not equal to <Zero>
VA rpt_TotalAmountTaxable = [VA rpt_TotalAmountTaxable]+[RV Extended Price]

VA rpt_SaveOrderTaxTXA1 = RV Tax Rate/Area
VA rpt_VertexGeoCodeShipto = RV Tax Rate/Area
VA rpt_SaveOrderTaxEXR1 = RV Tax Expl Code

Get Internal Next NUmber
VA rpt_VertexJobNumber <- mnJobnumberA

Load and Retrieve Vertex Cache
"2" -> cCalledFromFlag
RV Ship To -> mnSupplierOrShipTo
RV Invoice Date -> jdDateTransactionJulian
RV Order Company -> szCompany
RV Header Business Unit -> szHeaderBranchPlant
RV Business Unit -> szDetailBranchPlant
VA rpt_VertexJobNumber <> mnJobnumberA
"1" -> cModeProcessing
<Zero> -> cWriteRegisterFlag
RV Item Number (Short) -> mnIdentifierShortItem
RV Order Type -> szOrderType
RV Line Type -> szLineType
VA rpt_VertexGeoCodeShipto <> szShipToGeoCode
RV Order Number -> mnDocumentOrderInvoiceE
RV Order Company -> szCompanyKeyOrderNo
"000" -> szOrderSuffix
RV Line Number -> mnLineNumber
! VA rpt_VertexGeoCodeShipto = VA rpt_SaveOrderTaxTXA1

Tax, Calculate for Sales and Purchasing
VA rpt_SaveOrderTaxTXA1 -> szTaxArea1
VA rpt_SaveOrderTaxEXR1 -> szTaxExplanationCode1
RV Invoice Date -> jdTransactionDate
RV Payment Terms -> szPaymentTermsCode1
RV Order Company -> szCompany
RV Item Number (Short) <> mnShortItemNumber
RV Quantity -> mnUnitsPrimaryQtyOrder
RV Extended Price -> mnAmountTaxable
VA rpt_TaxesForLine <- mnAmtTax2
VA sec_TempDiscount <- mnAmtDiscountAvailable
VA rpt_StateTaxRate <- mnTaxRate1
VA rpt_CountyTaxRate <- mnTaxRate2
VA rpt_CityTaxRate <- mnTaxRate3
VA rpt_DistrictTaxRate <- mnTaxRate4
VA rpt_VertexErrorCode <- cErrorCode
"1" -> cSystemCode
VA rpt_VertexJobNumber -> mnJobnumberA
VA rpt_VertexActive -> cIsVertexActive
RV Order Number -> mnDocumentOrderInvoiceE
RV Order Type -> szOrderType
RV Order Company -> szCompanyKeyOrderNo
"000" -> szOrderSuffix
RV Line Number -> mnLineNumber

VA rpt_TotalTaxesExtended = [VA rpt_TotalTaxesExtended]+[VA rpt_TaxesForLine]
If VA rpt_VertexErrorCode is equal to <Zero>
End If
VA rpt_VertexErrorMsgDlt = "078N"
Delete Message(VA rpt_VertexErrorMsgDlt)
End If
F4211.Fetch Next
RV Order Company <- TK Order Company (Order Number)
RV Order Number <- TK Document (Order No, Invoice, etc.)
RV Order Type <- TK Order Type
RV Line Number <- TK Line Number
RV Order Suffix <- TK Order Suffix
RV Business Unit <- TK Business Unit
RV Company <- TK Company
RV Address Number <- TK Address Number
RV Ship To <- TK Address Number - Ship To
RV Order Date <- TK Date - Order/Transaction
RV Invoice Date <- TK Date - Invoice
RV Item Number (Short) <- TK Item Number - Short
VA rpt_PartNumberLITM <- TK 2nd Item Number
VA rpt_DetailDSC1 <- TK Description
RV Line Type <- TK Line Type
RV Status Code - Next <- TK Status Code - Next
RV Header Business Unit <- TK Business Unit - Header
VA rpt_DetailUOM <- TK Unit of Measure as Input
RV Quantity <- TK Units - Order/Transaction Quantity
RV Quantity Shipped <- TK Quantity Shipped
VA rpt_DetailUnitPrice <- TK Amount - Price per Unit
RV Extended Price <- TK Amount - Extended Price
RV Payment Terms <- TK Payment Terms Code
RV Payment Instrument <- TK Payment Instrument
RV Sales Taxable <- TK Sales Taxable (Y/N)
RV Tax Rate/Area <- TK Tax Rate/Area
RV Tax Expl Code <- TK Tax Expl Code 1
End While
 
Back
Top