Skip to content

JournalEntryAdd QBXML - Element TxnDate included gives an error #5

Description

@sherjackson

Hello, the following is showing in the QBXML SDK log file.

20171220.181153 E 7128 XercesSAXErrorHandler Element 'TxnDate' is not valid for content model: '(TxnDate?,RefNumber?,Memo?,IsAdjustment?,((IsHomeCurrencyAdjustment|(IsAmountsEnteredInHomeCurrency?,CurrencyRef?,ExchangeRate?)))?,ExternalGUID?,((JournalDebitLine|JournalCreditLine))+)' -- error at line 2, column 551 in XML data.

When I look at the XML being passed in it is as follows:

<?xml version="1.0"?><?qbxml version="13.0"?><QBXML><QBXMLMsgsRq onError="continueOnError"><JournalEntryAddRq requestID="CV-1"><JournalEntryAdd defMacro="TxnID:CV-1"><RefNumber>CV-1</RefNumber><TxnDate>2017-12-20</TxnDate><JournalCreditLine defMacro="LineTxnID:CV-1"><TxnLineID>CV-1</TxnLineID><AccountRef><ListID>80000033-1510159577</ListID></AccountRef><Amount>42.93</Amount></JournalCreditLine><JournalDebitLine defMacro="LineTxnID:CV-2"><TxnLineID>CV-2</TxnLineID><AccountRef><ListID>8000005B-1510159969</ListID></AccountRef><Amount>42.93</Amount></JournalDebitLine></JournalEntryAdd></JournalEntryAddRq></QBXMLMsgsRq></QBXML>

If I comment it out in the code it goes past this error. Thoughts as Journal Entries should really be able to have the date indicated on import as it may differ from current date.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions