how to increment invoice num with prefix
Posted: Tue Sep 29, 2020 5:38 pm
Hi Dear
I need your help how to increment invoice number thru textbox with prefix
Here is my code:
Best Regards
I need your help how to increment invoice number thru textbox with prefix
Here is my code:
Code: Select all
Private Sub UserForm_Initialize()
Dim irow As Long
Dim ws As Worksheet
Set ws = Worksheets("Accounts Receivable")
'find last row in database
irow = ws.Cells(Rows.Count, 1).End(xlUp).Row
TextBox1.Value = "INV-"& ws.Cells(irow, 1) + 1
End SubBest Regards