Invoice Post-Saving Hook (R-ITOTEN.MAC) ![]()
The script file must be located in your CAPITAL program directory and must have the file name R-ITOTEN.MAC. It is executed after an invoice system transaction has been saved. (This may include adjustment notes, stock transfers, and other types of invoicing related transactions.)
Entry Values
|
Variable |
Purpose |
|
Mode |
0 = normal. 1 = bulk generation of invoices. E.g., when releasing multiple invoices via service manager global invoicing or back order release. |
|
Action |
This is a 4 element array with the following structure: 1st form name number of copies to print of 1st form 2nd form name number of copies to print of 2nd form |
Return Values
None.
Example
* If the Carrier field on an invoice is left blank
* assign the default customer carrier to the
* transaction. This assumes that a user defined
* field called Carrier has been added to the
* customer screen
If IsEmpty(Invoice->Shipped)
Invoice->(Write("Shipped", Cuaux000->Carrier))
Endif
____________________________
Related Topics:
![]() |