'This is a MOD 10 Add-Double-ADD routine.
Friend Function ComputeAddDoubleAddCheckDigit(strAcctNo As String) As String
Dim L As Integer, _
strResponse As String, _
intCk As Integer, I As Integer
L = Len(strAcctNo)
If Not (strAcctNo Like String(L, "#"

) Or _
strAcctNo = String(L, "0"

Then
strResponse = "X"
Else
Dim aryAddDouble As Variant
'* Sum of digits in number after doubling e.g. 2*9 = 18 1+8 = 9
aryAddDouble = Array(0, 2, 4, 6, 8, 1, 3, 5, 7, 9)
For I = 15 To 1 Step -2
intCk = intCk + aryAddDouble(CInt(Mid$(strAcctNo, I, 1)))
Next
For I = 14 To 2 Step -2
intCk = intCk + CInt(Mid$(strAcctNo, I, 1))
Next
intCk = (1000 - intCk) Mod 10
strResponse = CStr(intCk)
End If
ComputeAddDoubleAddCheckDigit = strResponse
End Function
Forms/Controls Resizing/Tabbing Control
Compare Code (Text)
Generate Sort Class in VB or VBScript