the wrong number of arguments has been specified for the method.

I am creating code to post invoice for purchase order and when compile my code error appear at this point:
purchParmTable.TableRefId = FormLetter::getTableRef();
" the wrong number of arguments has been specified for the method."
can someone explain to me why this error occur?

HI,

The method “getTableRef()” require some variable to be pass with it.like getTableRef(x,y)

Thanks for the information vinoth…:slight_smile:

Hi,

PurchFormLetter PurchFormLetter;
purchtable purchtable;

purchtable = PurchTable::find(‘PONo’);
purchformletter = PurchFormLetter::construct(DocumentStatus::Invoice);
purchformletter.update(purchtable, strfmt(“Inv_%1”,purchtable.purchid), today(), PurchUpdate::All);

This code will post the invoice.