change the expiration, as would do to change those dates?

F

Frank Dulk

Do I have that procedure that generates a portion and and the collection
dates, where do I generate 400 portions, but after I create does imagine a
customer wants to change the expiration, as would do to change those dates?

Dim db As DAO.Database
Dim rs As DAO.Recordset
Dim ValParc As Currency
Dim i As Integer

Set db = CurrentDb()
Set rs = db.OpenRecordset("TblPagamento")
ValParc = Me.Total

For i = 1 To Me.qtparcelas
rs.AddNew
rs("pg_parcela") = i
rs("pg_codcliente") = Me.codassegurado
rs("pg_valorapagar") = ValParc
rs("pg_id") = Me.id
' It calculates the dates of Vencto through the function DateAdd ()
rs("pg_datavencimento") = DateAdd("m", i - 1, Me.datparc)

rs.Update
Next

rs.Close
db.Close
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top