This routine was adjusted to comply with the General Personal Data Protection Law (LGPD law No. 13.70), so that some fields containing data regarded as sensitive and/or personal are blurred, becoming illegible. |
Use this routine to generate checks before posting bills. You can generate a single check for several bills from the same supplier. The posting binds bank/branch/account/check.
Procedure manually performed through the Checks on Bills routine (FINA390), with the display of the screens involved in the process - actions/commands from the user are required
Procedure automatically performed in the Checks on Bills routine (FINA390) without the display of screen - no interaction from the user required.
Used in customizations in which the process does not required user's interactions (MSEXECAUTO)
#Include 'Protheus.ch' //--------------------------------- // CHEQUE SOBRE TITULOS | //--------------------------------- User Function 1DupPref() Local aArray := {} Local cCheque:= "2906001" Local nOpc := 2 // 2 - Chq s/ titulo, 3 - Avulso Private lMsErroAuto aArray := { { "AUTBANCO" , "237" , NIL },; { "AUTAGENCIA" , "33901" , NIL },; { "AUTCONTA" , "125008 " , NIL },; { "AUTCHEQUE" , cCheque , NIL },; { "AUTVENCINI" , CtoD("21/06/2016"), NIL },; // Remover caso utilizar opc 3 { "AUTVENCFIM" , CtoD("29/06/2016"), NIL },; // Remover caso utilizar opc 3 { "AUTVALOR" , 5000 , NIL },; { "AUTFORN" , "001" , NIL },; { "AUTBENEF" , "F PADRAO ", NIL },; { "AUTNATUREZA" , "10101 " , NIL }} MsExecAuto( { |x,y,z| FINA390(x,y,z)} ,0, aArray, nOpc) If lMsErroAuto MostraErro() Else Alert("O cheque "cCheque" foi gerado com sucesso!") Endif Return |
#Include 'Protheus.ch' //--------------------------------- // CHEQUE SOBRE TITULOS | //--------------------------------- User Function MyCanFA390() Local aArray := {} Local cCheque:= "2906001" Private lMsErroAuto := .F. aArray := { { "AUTBANCO" , "237" , NIL },; { "AUTAGENCIA" , "33901" , NIL },; { "AUTCONTA" , "125008 " , NIL },; { "AUTCHEQUE" , cCheque , NIL },; { "AUTCHQIMPR" , .T. , NIL }}// Identifica se deve ou não reutilizar o cheque caso impresso. MsExecAuto( { |x,y,z| FINA390(x,y,z)} ,0, aArray, 5) If lMsErroAuto MostraErro() Else Alert("O cheque "cCheque" foi cancelado com sucesso!") Endif Return |
Procedure to add checks that lack associated bills.
Procedure for the user to add and link a check to a bill that has not yet been posted.
Search for the bill in the accounts payable file, having it placed and highlighted in the browser.
Procedure to delete a check and cancel the bank transaction.
Display query with accounting entry of check, if it has already been booked.
Display caption chart and check status definitions
Procedure that reverses the transaction generated by the counter check operation
List of parameters applied to FINA390 and its processing
|
A check is a prompt payment order. When the issuer uses the Check on Bills operation to generate a check, they order a bank to pay a given amount to a beneficiary.
Besides a payment order, the check is also considered a "credit bill". That is, the issuer admits to a debt; thus, if payment is not made, the check can be protested or lead to a collection lawsuit.
The check is paid when a balance exists in the checking account to be verified in table SE8 - Bank Balances of the company/business unit/branch to which the user is logged. If there is no balance, the check is considered bounced and returned, requiring a Cancel operation.
You cannot generate Checks on Advance Payments, Deductions, Debit Notes to Suppliers and Provisional Bills. |
If you want to issue checks for Advance Payments, please use routine Automatic Postings Payable (FINA090) and, in parameters (F12), set option "Generate Check Autom." to YES. |
|
The booking of processes applied to a check added via Financials module is done through the standard entries below:
SE | Generator Fact | ON | OFF (CTBAFIN) |
566 | Generation of checks on bills pending | X | X |
567 | Generation of counter checks | X | X |
568 | Cancellation of Counter Check | X | X |
569 | Redeposit of checks on bills pending | X | X |
571 | Cancellation of checks on bills pending / Deletion of payment order | X | X |
Entry point | Note |
F390BROW | Entry Point that allows creating a filter in the browser of routine FINA390.Document: http://tdn.totvs.com/x/7qRc+ |
F390BFIL | Allows entering an expression for filtering bills on the main screen of the Check Generation routine, to run only in the TopConnect environment. Enter the expression in SQL.Documentation: http://tdn.totvs.com/x/oKRc+ |
A390HIST | Use entry point A390HIST to fill out field cHist390 (initialization of history in generation of checks on bills). |
F390FIL | Entry point F390FIL implements a condition in default filter of work file (table) when selecting bills to generate Checks on Bills. |
A390ACR | |
F390GCHE | Use entry point F390GCHE to handle the issue date of the check when generated through button "Check W/out Bill" of routine FINA390.Document: http://tdn.totvs.com/x/m6Rc+ |
A390SEF | Entry point A390SEF is used for complementary saving items of check on bill. It is executed after saving data to SEF. |
A390CHEQ | The entry point is called in the bill selection function for check generation (FA390tit). Entry point for processing checks before booking. |
A390AVU | The Entry Point is called in the check on bills generation program, on posting of bills or counter checks after saving check to SE5. |
F390CANC | Entry point that allows or prohibits check cancellation.Documentation: http://tdn.totvs.com/x/RaRc+ |
F390CBX | Entry point for saving complements after check cancellation. |
F390REDP | Use entry point F390REDP to save complementary SEF data when handling a redeposit. |
FA390NATUR | |
F390NATU | |
F390BEN | |
F390TIT | Entry point F390TIT checks the possibility of selecting the bill to compose the check. If the bill selection is changed, ExecBlock must return .F., so there is nochange to accumulators of values and numbers of bills.Document: http://tdn.totvs.com/x/YqVc+ |
FA390TOK | Use entry point FA390TOK in validation (All Okay) of data digitalized when generating checks and redepositing. You can use the following variables: cBanco390, cAgencia390, cConta390, cHist390, cNatur390, cCheque390, cForn390, cBenef390 e nValor390.Document: http://tdn.totvs.com/x/taNc+ |
F390FILUSU | Entry point for validation of bills for CH generation. |
F390GRV | The purpose of entry point F390GRV is to handle checks. It is called in function fa390Ver() before checking whether the cancellation refers to counter check or bill. |
F390CBX2 | Entry point for saving complements after check cancellation. |
<!-- esconder o menu --> <style> div.theme-default .ia-splitter #main { margin-left: 0px; } .ia-fixed-sidebar, .ia-splitter-left { display: none; } #main { padding-left: 10px; padding-right: 10px; overflow-x: hidden; } .aui-header-primary .aui-nav, .aui-page-panel { margin-left: 0px !important; } .aui-header-primary .aui-nav { margin-left: 0px !important; } </style> |