Xiq
Active Member
Hi all,
Here is my ISBN-converter / ISBN13-recalculator *flex*
Input is either ISBN10 or ISBN13, with or without the dashes.
What it basically does:
Here is my ISBN-converter / ISBN13-recalculator *flex*
Code:
=LEFT(IF(LEN(SUBSTITUTE(TEXT(B2,"#"),"-",""))=10,"978","")&SUBSTITUTE(TEXT(B2,"#"),"-",""),12)&SUM(((10-MOD(SUM(MID(LEFT(IF(LEN(SUBSTITUTE(TEXT(B2,"#"),"-",""))=10,"978","")&SUBSTITUTE(TEXT(B2,"#"),"-",""),12),ROW(A$1:A$12),1)*{1;3;1;3;1;3;1;3;1;3;1;3}),10))=ROW(A$1:A$10))*RIGHT(ROW(A$1:A$10),1))
Input is either ISBN10 or ISBN13, with or without the dashes.
What it basically does:
- Converting the ISBN10 to ISBN13 by adding the "978" (if needed)
- Then it removes the old control number (last digit), leaving the 12 digits.
- Recalculates the new ISBN13 control number.
- Add the 12 digits & control number together
- ...
- Profit!