Page 1 of 1

Re: AddInventoryItem returning FALSE even though adding line

PostPosted: Mon Apr 26, 2021 12:06 pm
by Scott.Pearce
AddInventoryItem does not return a boolean. It returns a JiwaSalesQuote.clsSalesQuoteLines.SalesQuoteLineReturnCodes

You are implicitly casting a "JiwaSalesQuote.clsSalesQuoteLines.SalesQuoteLineReturnCodes" type into a boolean type. Don't do this.

Your call should look like this:

Code: Select all
If AddInventoryItem(InvItem.InventoryID, e_SalesQuoteLineInventoryID, NewLineKey, Row + MyLoop) = e_SalesQuoteLineReturnCodeSuccess Then

Re: AddInventoryItem returning FALSE even though adding line

PostPosted: Mon Apr 26, 2021 5:05 pm
by Scott.Pearce
Is this in VBScript?