N
Nylex
I use a set routine in quite a few forms
I have written the function and Have tested it and it always get the correct
answer
When I return from the function I can not find the answer
This is how I call it
NewInvoice (LastInv)
Debug.Print InvDate, NextInv
Stop
Function NewInvoice(LastInv)
Dim nID As Integer
nID = Val(Mid(LastInv, 2))
NextID = "S" & Format(nID + 1, "00000")
NextInv = NextID
End Function
LastInv is a string and so is NextInv and NextID
I have written the function and Have tested it and it always get the correct
answer
When I return from the function I can not find the answer
This is how I call it
NewInvoice (LastInv)
Debug.Print InvDate, NextInv
Stop
Function NewInvoice(LastInv)
Dim nID As Integer
nID = Val(Mid(LastInv, 2))
NextID = "S" & Format(nID + 1, "00000")
NextInv = NextID
End Function
LastInv is a string and so is NextInv and NextID