validation procedure
Description
must be active
Parameters
| iiTargetField | input | integer | Value of the business field to validate. |
| icTargetFieldName | input | character | Name of the business field to validate. |
| icRowid | input | character | Contents of field tc_Rowid, if the target field is a field of a component temp-table. |
| ilActive | input | logical | Active flag |
| icVatInOut | input | character | Vat In Out |
| oiReturnStatus | output | integer | Return status of the method. |
Internal usage
QadFinancials
program code (program5/bcinvoice.p)
if not ilActive
then do:
<M-1 run SetMessage
(input trim(#T-3'You can only specify active tax codes.':150(966)t-3#) (icMessage),
input '':U (icArguments),
input icTargetFieldName (icFieldName),
input string(iitargetField) (icFieldValue),
input 'E':U (icType),
input 3 (iiSeverity),
input icRowid (icRowid),
input 'QADFIN-368':U (icFcMsgNumber),
input '' (icFcExplanation),
input '' (icFcIdentification),
input '' (icFcContext),
output viFcReturnSuper (oiReturnStatus)) in BCInvoice>
assign oiReturnStatus = -1.
end.
if icVatInOut <> {&VATINOUT-INPUT}
then do:
<M-2 run SetMessage
(input trim(subst(#T-4'You can only specify tax codes of type &1.':150(967)t-4#, {&VATINOUT-INPUT-TR})) (icMessage),
input '':U (icArguments),
input icTargetFieldName (icFieldName),
input string(iitargetField) (icFieldValue),
input 'E':U (icType),
input 3 (iiSeverity),
input icRowid (icRowid),
input 'QADFIN-1101':U (icFcMsgNumber),
input '' (icFcExplanation),
input '' (icFcIdentification),
input '' (icFcContext),
output viFcReturnSuper (oiReturnStatus)) in BCInvoice>
assign oiReturnStatus = -1.
end.