Jump to content
Fivewin Brasil

MrBoleto Banco Santander


jfaguiar

Recommended Posts

Boa tarde amigos.

Alguém teria a classe MrBoleto com a montagem da linha editável atualizada para o Banco Santander.

Creio que o método abaixo está desatualizado, pois a linha editável gerada não bate com o do site e nem com o da cobrebem.

Obriagdo

 

Segue o método:

Method Banco_033() Class MR_Boleto

   ::Banco_Dv_____ := "7"
   ::Banco_Nome___ := "Banco Santander"

   IF EMPTY( ::Prefixo______ )
      ::Prefixo______ := ::Conta________
      ::Conta________ := ''
      ::Prefixo_DV___ := ::Conta_DV_____
      ::Conta_DV_____ := ''
   ENDIF

   ::Prefixo______ := PADL( ALLTRIM( Left( ::Prefixo______,  6 ) ),  6, '0' )
   ::Prefixo_DV___ := PADL( ALLTRIM( Left( ::Prefixo_DV___,  1 ) ),  1, '0' )

   ::NossoNumero__ := PADL( ALLTRIM( Left( ::NossoNumero__, 12 ) ), 12, '0' )
   ::NossoNumer_DV := ::DC_Mod11( ::Banco________, 9, .F., ::NossoNumero__, .F. )

   ::NossoNumero_z := ::NossoNumero__ + " " + ::NossoNumer_DV

   ::Ag_Cod_Cedent := TRAN( ::Banco_Agencia + '/' + ::Prefixo______ + '-' + ::Prefixo_DV___, "@!")

   ::Campo_Livre__ := '9' + ::Prefixo______ + ::NossoNumero__ + ::NossoNumer_DV  + '0102'

   Return NIL

//*----------------------------------------------------------------------------*
 

 

Link to comment
Share on other sites

Aguiar, faz tempo que não lido com isso. O último ajuste foi em 2015, estava funcionando ao menos até 2017.
Segue o código que tenho aqui:
 

//*----------------------------------------------------------------------------*
//
// M., Ronaldo: Boleto Bancario em Harbour
//
// Method Banco_033() Class MR_Boleto
//
//*----------------------------------------------------------------------------*
Method Banco_033() Class MR_Boleto

   ::Banco_Dv_____ := "7"
   ::Banco_Nome___ := "Banco Santander"

   IF EMPTY( ::Prefixo______ )
      ::Prefixo______ := ::Conta________
      ::Conta________ := ''
      ::Prefixo_DV___ := ::Conta_DV_____
      ::Conta_DV_____ := ''
   ENDIF

   ::Prefixo______ := PADL( ALLTRIM( Left( ::Prefixo______,  6 ) ),  6, '0' )
   ::Prefixo_DV___ := PADL( ALLTRIM( Left( ::Prefixo_DV___,  1 ) ),  1, '0' )

   ::NossoNumero__ := PADL( ALLTRIM( Left( ::NossoNumero__, 12 ) ), 12, '0' )
   ::NossoNumer_DV := ::DC_Mod11( ::Banco________, 9, .F., ::NossoNumero__, .F. )

   digNossoNumero := ::DC_Mod11( ::Banco________, 9, .F., ::NossoNumero__, .F. )

   ::NossoNumero_z := ::NossoNumero__ + " " + ::NossoNumer_DV

   ::Ag_Cod_Cedent := TRAN( ::Banco_Agencia + '/' + ::Prefixo______ + '-' + ::Prefixo_DV___, "@!")

   ::Campo_Livre__ := '9' + ::Prefixo______ + ::Prefixo_DV___ + ::NossoNumero__ +  + ::NossoNumer_DV  + '0'+ ::Carteira_____

   Return NIL

 

Sds.

Link to comment
Share on other sites

 

Aguiar, faz tempo que não lido com isso. O último ajuste foi em 2015, estava funcionando ao menos até 2017.
Segue o código que tenho aqui:
 


//*----------------------------------------------------------------------------*
//
// M., Ronaldo: Boleto Bancario em Harbour
//
// Method Banco_033() Class MR_Boleto
//
//*----------------------------------------------------------------------------*
Method Banco_033() Class MR_Boleto

   ::Banco_Dv_____ := "7"
   ::Banco_Nome___ := "Banco Santander"

   IF EMPTY( ::Prefixo______ )
      ::Prefixo______ := ::Conta________
      ::Conta________ := ''
      ::Prefixo_DV___ := ::Conta_DV_____
      ::Conta_DV_____ := ''
   ENDIF

   ::Prefixo______ := PADL( ALLTRIM( Left( ::Prefixo______,  6 ) ),  6, '0' )
   ::Prefixo_DV___ := PADL( ALLTRIM( Left( ::Prefixo_DV___,  1 ) ),  1, '0' )

   ::NossoNumero__ := PADL( ALLTRIM( Left( ::NossoNumero__, 12 ) ), 12, '0' )
   ::NossoNumer_DV := ::DC_Mod11( ::Banco________, 9, .F., ::NossoNumero__, .F. )

   digNossoNumero := ::DC_Mod11( ::Banco________, 9, .F., ::NossoNumero__, .F. )

   ::NossoNumero_z := ::NossoNumero__ + " " + ::NossoNumer_DV

   ::Ag_Cod_Cedent := TRAN( ::Banco_Agencia + '/' + ::Prefixo______ + '-' + ::Prefixo_DV___, "@!")

   ::Campo_Livre__ := '9' + ::Prefixo______ + ::Prefixo_DV___ + ::NossoNumero__ +  + ::NossoNumer_DV  + '0'+ ::Carteira_____

   Return NIL

 

Sds.

Olá Rogério.

D e u   C e r t o !!!

Atualizei o método e alterei o carregamento das seguintes variáveis da seguinte forma:

 oBoleto:Prefixo______ := ''
 oBoleto:Prefixo_DV___ := ''

Obrigado rapaz.

Deus te abençoe...

Feliz ano novo
 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...