Link to home
Start Free TrialLog in
Avatar of sandra_wallace
sandra_wallace

asked on

Calculate an ISBN checksum?

Hello Everyone,

I am trying to automate a few things here at the office for everyone. One of my projects is to create a simple program (very simple) that calculates the checksum or check digit of an ISBN number.

For example:
If you had an ISBN number of 157521030, the checksum would be 4. I've seen examples to verify the checksum, and I've seen the mathmatical equation, but I was wondering if anyone had a simple function or routine that does this? Perhaps a pointer to one that does?

Any help or guidance would be greatly appreciated.

Sincerely,

Sandra Wallace
sandra_wallace@yahoo.com

Avatar of sandra_wallace
sandra_wallace

ASKER

Edited text of question
ASKER CERTIFIED SOLUTION
Avatar of rwilson032697
rwilson032697

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Oops,  this line

 result := chr(asc('0') + ModValue - 1)

should read

 result := chr(ord('0') + ModValue - 1)

Cheers,

Raymond.