Check Digit MOD 10 w/ weights 7-5-3-2

Category:
Dates and Math
Type:
Snippets
Difficulty:
Intermediate
Author:
Anonymous

Version Compatibility: Visual Basic 6, Visual Basic 5

More information:
Many financial institutions that provide OCR (Optical Character Recognition) scanning for, say, lockbox processing require the scanable line to have one or more check digits. Based on the documentation I've seen, one common check digit method is MOD 10 with weights of 7-5-3-2. This function calculates a check digit for any numeric string up to 100 characters in length.

Instructions: Copy the declarations and code below and paste directly into your VB project.

Declarations:

Code: