GaryPanic
10-30-2007, 03:46 PM
guys ,
i have a bit of coding that works a charm (not mine)
anyway it get me a unique number in squence ---
Dim NextNo As Long
Dim rs As DAO.Recordset
Set rs = CurrentDb.OpenRecordset("SELECT NextNum FROM tblnextnum")
NextNo = rs!nextnum + 1
'now update the table
rs.Edit
rs!nextnum = NextNo
rs.Update
rs.Close
Set rs = Nothing
Me.lastinvoiceno = NextNo
now I need to have 4-5 numberings so what I wanted was 1 table for all my numbers to be in-
i presume its just rename NextNo
in my first case it would be
Quoteno everywhere Nextno appears .(its late and I not thinkking straight ...)
does that sound right ???
tyour thoughts
gp
i have a bit of coding that works a charm (not mine)
anyway it get me a unique number in squence ---
Dim NextNo As Long
Dim rs As DAO.Recordset
Set rs = CurrentDb.OpenRecordset("SELECT NextNum FROM tblnextnum")
NextNo = rs!nextnum + 1
'now update the table
rs.Edit
rs!nextnum = NextNo
rs.Update
rs.Close
Set rs = Nothing
Me.lastinvoiceno = NextNo
now I need to have 4-5 numberings so what I wanted was 1 table for all my numbers to be in-
i presume its just rename NextNo
in my first case it would be
Quoteno everywhere Nextno appears .(its late and I not thinkking straight ...)
does that sound right ???
tyour thoughts
gp