Calculate The Check DigitNov 1, 2009
who can provide me a full formula enabling me to calculate the check digit(MOD 10) of the a given number?
who can provide me a full formula enabling me to calculate the check digit(MOD 10) of the a given number?
How do I create a formula that will calculate a check digit for a 9-digit number using MOD 10? The weighting is 212121212. The problem I am having is that if the sum of the product is in double digits, they must be treated as individual digits.
Number To Be Calculated: 0 0 4 4 5 5 5 2 5
Weighting: 2 1 2 1 2 1 2 1 2
22/10 = 2 r2
10-2 = 8 (Check Digit)
Is it possible to create such a formula? I need to calculate several hundred and do not want to do this manually!
How to calculate a check digit in excel. The details to calculate this are as follows:
All variables in the calculation are positive integers.
We take each integer of the pro number and multiply it by a value and sum them to get a total.
An Example: 8 Digit Pro Number: 66988757
Pro Number: 6 6 9 8 8 7 5 7
Position in the Pro Number: 1 2 3 4 5 6 7 8
Multiply each digit in the pro number by (10-position) in the number, to achieve a sum.
Using our example pro again:
6*(10-1) + 6*(10-2) + 9*(10-3) + 8*(10-4) + 8*(10-5) + 7*(10-6) + 5*(10-7) + 7*(10-8)
6*9 + 6*8 + 9*7 + 8*6 + 8*5 + 7*4 + 5*3 + 7*2
54+ 48+ 63+48+40+28+15+14 = 310
Take the Sum of the previous calculation and divide it by 11
310/11 = 28
(Actually, it's 28.181818, but since we're working with integers, we truncate everything behind the decimal).
Figure a remainder by multiplying the quotient by 11 and subtracting from the sum.
Remainder = 310 - (28*11) ---> Remainder = 310 - 308 ----> Remainder = 2
Check Digit = 11- Remainder
Check Digit = 11 - 2 ---> Check Digit = 9
Note: if the check digit is 10 or 11, need to subtract 10 from the Check Digit.
My company uses 4 types of barcodes 8, 12, 13, & 14 number barcodes for our products my problem is that I can't figure out how to force the barcode to format properly no matter how somebody enters it if they don't use spaces or put them in the wrong spots, I can't use custom formats because there is 4 different layouts
8 digit should be "#### ####"
12 digit should be "###### ######"
13 digit should be "# ###### ######"
14 digit should be "# ## ##### ######"
these barcodes are in columns L, M, & N also right now 'm using a formula in another cell to verify the barcodes by calculating the check digit and comparing it to the check digit typed the formula i'm using is
I wanna create a buildin check digit for container numbers
so it will exists out of 11 cells. ( GATU 021097-9 )
is it possible when u type any letter/number in the first cell on a row it automaticly jumps to the next cell, repeating this for the full container number ?
I have a spreadsheet that pulls in a log file after running a macro with 100000eight digit numbers which may or may not have a record in the system. These numbers are produced by using any seven digits and adding a check digit at the end for an eight digit number using the mod function specifically Mod7...=MOD(A1,7) , for example, if cell A1 has 1234567 the mod7 function will produce the check digit 5 then concatenating for the eight digit number 12345675. the next number will be produced by adding 1 to the end of the 7 digit number 1234567+1=1234568 then concatenating again the number with the check digit 6, 12345686. this would be sequential order.
my spreadsheet gets all the eight digit numbers with no record and sorts them in MOD7 sequential order in one column. since the spreadsheet ignores the eight digit numbers with records. my compiled list of numbers have non sequential numbers in the list.
i need a way in VB to loop through 100000 lines (column A) and find the first and last number of a MOD7 sequential range and place the first number in (column B) and the last in (column C).
I have figured a way to do this in a spreadsheet but it takes too many functions and calculations in 100000 lines so the spreadsheet takes too long to open and sometimes crashes!
Combining two equations with MOD function for UPC check digit calculation.
I wanted to combine these if possible,
This is my code. It is for checking that only a 4 digit fiscal year is entered in a cell. The code works fine except it only checks a max of three time. So if the user enters xxx it will prompt for a correct response three times, if xxx is entere a 4th time then that value appears in the cell. I was wondering why this is taking place.
Here is my
I know you can take a number from one cell and combine it with number from another cell and make it one number. What I need to do is the reverse. Take a two digit number in a cell and separate it into single digits in two cells. If you have the number 50 in a cell, then is there a formula that will take the 5 and put it in cell and take the 0 and put it in the cell beside it?View 4 Replies View Related
I have a column of 6 digit numbers in excel, and I need to remove the last digit from each number, turning it into a 5 digit number. No rounding, just simply remove the last digit. Each number is different. Does anyone know how to quickly and efficiently remove the last digit from each number? I can convert to alphanumeric string if need be...View 4 Replies View Related
I need a macro where I can highlight a column and change all of the 2 digit years to a 4 digit year (actually, some of the 2 digit years are only 1 digit, e.g. "9" instead of "09").
I have an if then statement that I can use in the column after it, but I'd rather change the actual numbers in the original column, rather than adding another column (and having to keep the original, too).
The statement I had was:
I just copy dragged down to get the cell numbers for the rest of the column... but using A1 was just for an example, here, it's not necessarily going to be in that column. It needs to be just whichever cells I select.
It seems like it should be pretty simple, but I don't know how to word it in a macro.
Starting Column Example:
For some reason I can't get rid of the borders...
I have an address (city, state, zip format) in a cell. Some of the zip codes only have a 4-digit zip code which is the way the file was received. I know these zip codes have leading zero. How can I convert these to a five-digit code. Examples are as follows:
Waltham MA 2453
convert to 'Waltham MA 02453'
Boston MA 2210
convert to 'Boston MA 02210'
CEDAR GROVE, NJ 7009-1174
convert to 'CEDAR GROVE, NJ 07009-1174'
TEANECK CITY, NJ 7666
convert to 'TEANECK CITY, NJ 07666'
I have 2 digit years (98, 99, 00, 01) that I need to convert to 4 digit years (1998, 1999, 2000, 2001). There is one year per cell. If it was simply a matter of adding 19 or 20 to the beginning of each, I could do that. But since there's a combination of both 19 and 20 that needs to be added and there all intermingled, I'm not sure how to do it.
Can a rule be written to add 19 to the beginning except if the current cell starts with a 0, then add 20? The highest year is 2008 (no 2010 to deal with).
98 --> 1998
99 --> 1999
00 --> 2000
01 --> 2001
I have data in Row 53 that spans 7 columns, but stays in the same row. I want to design a loop to select every 7th cell in that row and check if it is empty. If not, add onto a "counter" then display the final number of occupied cells (the value of the counter) at the end. This is what I have so far, but I get all sorts of errors.
Dim WB As Workbook
Dim WS As Worksheets
Dim modCounter As Long
Dim Cell As Range
Set WB = Workbook("Transverse Series.xlsm")
Set WS = WB.Sheets(BM18)
I am using this codeView 5 Replies View Related
How do you remove the last 2 digit
So in column B is would show
Say I have a sets of numbers in column A as below:
I know the formula to select the last number:
=RIGHT(A1,1) gives the answer 3
=RIGHT(A2,1) gives the answer 9
To select the last 2 numbers is:
=RIGHT(A1,2) gives the answer 23
=RIGHT(A2,2) gives the answer 89
My query is to select ONLY the 2nd last digit (being 2 in A1 or 8 in A2).
Is there a way to build a 12 digit calculator in excel?View 9 Replies View Related
My question is, a formula was provided to me that add's a comma and a space after a 15 digit sequence of numbers, that formula is:
And what that does is it would change data in a cell that looks like this
01-02-034-05-W2 TO 02-03-045-06-W2
01-02-034-05-W2 TO 02-03-045-06-W2 ,
The formula works great, thanks to the help of the posters!
However I just ran into an issue, what if I have a set of data in a cell that looks like this:
01-02-034-05-W2 TO 02-03-045-07-W2
02-02-034-05-W2 TO 02-03-045-07-W2
03-02-034-05-W2 TO 02-03-045-07-W2
And I need a space and a comma at the end of each sequence, so the above would change to this after the formula is applied:
01-02-034-05-W2 TO 02-03-045-07-W2 ,
02-02-034-05-W2 TO 02-03-045-07-W2 ,
03-02-034-05-W2 TO 02-03-045-07-W2 ,
Now the data in the cell is wrapped so it lists one set of numbers, then the next set, then the next set as seen above.
I have column a with 1000 ten digit numbers. I need to remove the
digit in the fourth place from the left side in the entire column. I don't know how .
how you can determine if a cel value is a number or a digit
It is actually for a column to determine if it has a heading or not and acordingly y have to count the rows off that "current region" and put some values with a formula next to this column.
Y was testing an expression with this
msg = IIf(target.End(xlUp).Value = "X", "is this a LETTER", "is this a DIGIT")
I am trying to sort a spreadsheet in descending order of a certain column. I have been able to do so quite easily in the past. However, for some reason, when I am trying to sort it now, it is sorting based only on the first digit of the number in the cell. For example, the order after sorting may end up as 90, 9, 9, 82, 8, 8, 8, 74, etc. I don't know what happened to cause the change, or how to fix it.View 6 Replies View Related
Well I want to add few numbers in a few number for example I have ten columns containing few cell numbers and i want to add 92 my country code with it. I have tried this by using replace formula but in result it comes in text format from which i cannot use another formula unless text format is removed and for that i have to do it one by on in every single cell. I have attached a sample sheet.View 4 Replies View Related
Imagine a cell has a value of "008281" at A1
I want to return the first digit of the 6 digits in A1 which will be "0" in A2.
I tried using the formulae in A2 with "=left(A1,1), it returns "8" instead.
I have data in cells A1:Z1. The data is all 1 digit numbers, but sometimes they have asterisks behind the number. For instance in cell A1, I have 4, but in B1 I have 3**. I want to take the first digit of each cell and add it together and the result to be in AA1. The only thing I can think of doing is =SUM(LEFT(A1), LEFT(B1)...) but that's going to take too long (especially as I add columns).View 3 Replies View Related
I have a slight problem...I have a range of values..
I need to count the occurance of a a particular no. from 0-9.. So i want to know how many times say 0 appears in that range of values etc so on till 9. I tried using CountIF but the problem i face is lets say in my cell 0903 there are 2 0s inside, it doesnt count this 2 zero..
How can I get one cell to increase by 1 after I change the date in another cell. The spreadsheet is used to keep track of Oxygen Bottles at the local Fire Dept. and I want the " Times Filled" cell to increase by 1 after the " Date Filled" cell is changed. I'm not sure if they key the date in or if they use a calender add-in pop up.View 5 Replies View Related
I have many dates in a column in a 6 digit format such as:
These dates are Feb 23, 1995; Feb 24, 1995 etc.
How can I convert these dates in the column to 2/23/1995, 2/24/1995 etc?
I have the following dates in a column and need to convert them to the short date format:
91113 (Sept 11, 2013)
100713 (Oct 07, 2013)
122612 (Dec 26, 2012)
40413 (April 04, 2013)
Those are just some examples. When I convert these as is I get dates that are really far in the future. Some dates are 5 digit and some are 6.
I have column b filled with 17000 plus numbers formatted as text. I need an easy way to delete the first character on the left in each cell provided it is a zero.View 2 Replies View Related
I have the following
AK5 value will be 2 - 21.
I need it to display
or whatever the number is after A1D, but when AK8 = a value of 1 or 2 or 3...... It comes back as A1D1 or A1D2... How ca I keep the two digits in AK8 to stay and put the value the way I want in AE5 ...
I have simple (or not) question:
how can I convert a digit that I input into a cell to an hour format ?
I want to achieve something like this:
- when I input a digit into a cell , for example: 9 a want to convert it to 9:00 (9 hours, 0 minutes). How can I do it ?
I am trying to find a way to turn the raw data below, into the results on the right. Specifically I would like to extract any 5 digit (denoted by "." as a break) numrical value from the cells in column A (there could be as many as 20, 5 digit numurical values, id like each one listed in b2, c2, c3, and so on)
2abc.k(p).nov20.99375.65487.12354.jan13.p 99375 65487 12354
5tge.s.96514.jan15.96548 96514 96548
IS THERE A FORMULA TO CONVERT THE 5 DIGIT # INTO ITS CORRESPONDING DATE?View 9 Replies View Related
I'm trying to figure out how to setup a worksheet to find the most common 2 digit numbers going vertically from the bottom(cold) to the top(hot) it would consist of 90 digits 0 thru 9
it would look like this
4 0 3 9 0 4 3 3 2
9 2 5 6 5 6 9 6 6
8 9 9 3 1 0 2 9 8
1 6 7 5 9 9 8 2 5
2 7 2 2 2 8 5 1 3
0 1 4 7 4 7 6 0 9
3 5 6 4 3 3 0 4 4
7 8 8 1 8 5 7 8 7
5 4 1 8 6 1 1 5 1
6 3 0 0 7 2 4 7 0
each vertical line would be considered weeks 9 thru 1. week 9 would be the first vertical line of digits on the left. it could also contain the most common 2 digits horizontally. Both 2 digit values would be color coded ex. blue equals most common 2 digit horizontally and green equals vertically. I would also like to color code the most common 2 digit value diagonally as long as it is the most common of either the vertical or horizontal 2 digit. Each number is seperate on the worksheet they would not be pairs. im using excell 2003.
The last digit of a number (can be any demonination but always an integer). I know that you can check the last digit of a number with =RIGHT(A1,1) but I would like to check whether the last digit in number is 1,2,3,4,5 and if so change the whole number to a number ending in 5. If the original number ends in 0,9,8,7,6 then I want it to be changed to end in 9. Is this possible and if so is there an excel function that I could use??
e.g. 143 -> 145
e.g. 1037 -> 1039
I am importing data from a .csv file. The file contains dates like 02/15/40. The year is 2040, not 1940. Excel doesn't seem to use the Control Panel -> Regional Settings change when I open this file. I have my Regional Settings set to 2000 => 2099 to change to a two digit year. If I open a blank worksheet and type in 2/15/40 in a cell...Excel does the correct conversion to 2040. However, when I open a .csv file it considers it 1940.View 2 Replies View Related
I have a cell with a number which is a result of several previous sums. It's a number with 8 to 11 digits. For example: 878567663.
I need to add each digit of the number, and then add again the result until I end up with a single digit. In the above example it'd be (8+7+8+5+6+7+6+6+3=56), then (5+6=11), then (1+1=2) and put the end result (2) in a cell
My main doubt is that I don't know how to use a simple "do while" type structure in Excel to achieve the above.
1.) How do I create a formula to do that?. I have seen solutions in this board that let me add each digit but that's it... I need to "reduce" it until only one digit is left...
2.) What about if the lenght of the number is not always the same (fe. in one cell is 8, in another is 11, the next one is again 8...)?
I have some alphanumeric mixed data which is from 15 digits to 18 digits. In each data there have 5 zeros in the middle. I want to keep all the alphanumeric to 15 digits only. It will delete the zeros not any other value which length is greater than 15 digits. If a length of a character is 17 digit it will delete 2 zeros & if it is 15 digit then keep it constant.
Like: AJSPP00000125467 change to AJSPP0000125467.
I need composing a formula that will add a space after every 4th Number in a 16 digit Character Set.
ex. 0101 0101 0101 0101
So what i need is a 6 digit alpha numeric random (1000 entries)
so from some searching i figured that it should be...
MID (A1,1+INT(RAND()*LEN(A1)),1)&MID(A1,1+INT(RAND()*L EN(A1)),1)&MID(A1,1+INT(RAND()*LEN(A1)),1)
but when i fill down it auto it to a2 , then a3 etc... how do i stop that?
I might delete out the o O and 0 cause it gets confusing...
Also, it re-randomizes every time I open the file... is there a way to stop it?