QuickBooks Integrator 2020 C++ Edition

Questions / Feedback?

Cancel Method

Cancels (voids) the transaction.

Syntax

ANSI (Cross Platform)
int Cancel();

Unicode (Windows)
INT Cancel();
- (void)cancel;
#define MID_JOURNALENTRY_CANCEL 3

INQB_EXTERNAL int INQB_CALL InQB_JournalEntry_Do(void *lpObj, int methid, int cparam, void *param[], int cbparam[], int64 *lpllVal);

Remarks

Cancel causes the transaction to be voided in QuickBooks. The amount of the transaction and all line item quantities are changed to zero, and the memo is changed to "VOID:". The transaction will not, however, be deleted.

The transaction canceled in QuickBooks is the one specified by RefId. If the value of RefId is known then Get should first be called to retrieve the transaction. Otherwise the ObjSearch class should be used to search for the desired transaction in the QuickBooks database.

As the QuickBooks response to Cancel does not include the updated transaction, the values of all properties are instead set to their defaults. To get a copy of the updated transaction, the value of RefId should first be stored, and then Get should be called.

Error Handling (C++)

This method returns a result code; 0 indicates success, while a non-zero error code indicates that this method encountered an error during its execution. If an error occurs, the GetLastError() method can be called to retrieve the associated error message. (Note: This method's result code can also be obtained by calling the GetLastErrorCode() method after it returns.)

Copyright (c) 2021 /n software inc. - All rights reserved.
QuickBooks Integrator 2020 C++ Edition - Version 20.0 [Build 7941]