3rd digit fixed input DV

Zacheryryan93

New Member
Joined
Apr 2, 2022
Messages
10
Office Version
  1. 365
Platform
  1. Windows
I'm trying to set up a sheet for part numbers and new to DV formats in excel.

the format I need should look like "##1###", Where the 3rd digit is a fixed number, and always 6 digits. I will have 9 columns where the 3rd digit is 1-9 in each. I'm capable enough to change the values between columns myself but having trouble getting the base format down. i have tried piecing together parts of similar formats with no success. I Know its not as complicated as it is being, I'm just unaccustomed to the logic of excel and haven't messed with any type of coding for 10+ years

Thanks in advance
 

Excel Facts

Wildcard in VLOOKUP
Use =VLOOKUP("Apple*" to find apple, Apple, or applesauce
Hi,

Assuming your 6 digit numbers will Not have leading 0 (zeros), and assuming you're starting from Column A to Column I (you say 9 columns), select A1:I#, where # is your last row for DV
Use this formula:

If your Columns for DV is elsewhere, formula will need to be modified, in that case, please specify which columns needs the DV.

Book3.xlsx
ABCDEFGHI
1121456122456123456124567235789366541727895628754619855
Sheet1063
Cells with Data Validation
CellAllowCriteria
A1:I1Custom=AND(LEN(A1)=6,ISNUMBER(A1),MID(A1,3,1)+0=COLUMNS($A1:A1))
 
Upvote 0
Hi,

Assuming your 6 digit numbers will Not have leading 0 (zeros), and assuming you're starting from Column A to Column I (you say 9 columns), select A1:I#, where # is your last row for DV
Use this formula:

If your Columns for DV is elsewhere, formula will need to be modified, in that case, please specify which columns needs the DV.

Book3.xlsx
ABCDEFGHI
1121456122456123456124567235789366541727895628754619855
Sheet1063
Cells with Data Validation
CellAllowCriteria
A1:I1Custom=AND(LEN(A1)=6,ISNUMBER(A1),MID(A1,3,1)+0=COLUMNS($A1:A1))
Pops up in error, But if I bypass and use it anyways, it does work on the first row of the column. Also to clarify, columns with input specifications are as follows, G, 1; H, 2; I/J, 5; K/L, 3; M/N/O/P/Q (unsure if easier to script together or just copy/paste with change to information on column), 6; R, 4; S, 8/9 (7 is unused) and all columns may, though uncommon, lead with a zero. I am currently on row 1600 and working with a sheet that was implemented at the beginning of last year by someone who knows less than I know myself. The main reason and issue with this are that information is being entered into the wrong columns. We have implemented a color coordination with this as well and if this becomes too big of an ask, that will at least help the ones who aren't getting with the program slightly.

Apologizing for there being more to this than I initially led on, but I've since realized myself that it wasn't as simple as I initially thought.
 
Upvote 0
Please clarify, is the below correct?

Book3.xlsx
FGHIJKLMNOPQRS
13rd digit must be>1255336666648 or 9
Sheet1063


And, if the "numbers" may start with 0 or 0s, then the cells must be formatted as Text, is that also correct?
 
Upvote 0
Please clarify, is the below correct?

Book3.xlsx
FGHIJKLMNOPQRS
13rd digit must be>1255336666648 or 9
Sheet1063


And, if the "numbers" may start with 0 or 0s, then the cells must be formatted as Text, is that also correct?
That is all correct! Sorry for the delayed response. I do not have access to company email outside of the facility.
 
Upvote 0
This is a Single DV formula for your Range Column G:S, assuming you're starting at G1600
Select your range G1600:S####, where #### is the last row for DV.
Change/adjust cell reference accordingly.
DV, Custom, enter formula below.

Excel Formula:
=AND(LEN(G1600)=6,ISNUMBER(G1600+0),IF(COLUMN()=19,OR(MID(G1600,3,1)+0=8,MID(G1600,3,1)+0=9),MID(G1600,3,1)+0=CHOOSE(COLUMN()-6,1,2,5,5,3,3,6,6,6,6,6,4)))

Formula can be Much shorter if we do individual formulas for Each Column G:S, but you're going to end up with 13 different formulas, and it's probably more hassle than using just 1 long formula.
 
Upvote 0
This is a Single DV formula for your Range Column G:S, assuming you're starting at G1600
Select your range G1600:S####, where #### is the last row for DV.
Change/adjust cell reference accordingly.
DV, Custom, enter formula below.

Excel Formula:
=AND(LEN(G1600)=6,ISNUMBER(G1600+0),IF(COLUMN()=19,OR(MID(G1600,3,1)+0=8,MID(G1600,3,1)+0=9),MID(G1600,3,1)+0=CHOOSE(COLUMN()-6,1,2,5,5,3,3,6,6,6,6,6,4)))

Formula can be Much shorter if we do individual formulas for Each Column G:S, but you're going to end up with 13 different formulas, and it's probably more hassle than using just 1 long formula.
Not getting that to work either. That's got to be pretty close. If you break it down each section comes up as testing okay but all together it comes back in error. I hope you're enjoying this as much as I am. This has burned up quite a bit of my down time haha
 
Upvote 0
What Exactly is your starting cell, and what Exactly is the Range you're applying DV to ?
The formula has to be written and placed correctly according to the range.
 
Upvote 0
What Exactly is your starting cell, and what Exactly is the Range you're applying DV to ?
The formula has to be written and placed correctly according to the range.
just as test I started with G2000 and the range was to 2300
 
Upvote 0
And the Column Range is G:S ??
Did you change the Starting cell from G1600 to G2000 in the formula ???
 
Upvote 0

Forum statistics

Threads
1,214,885
Messages
6,122,085
Members
449,064
Latest member
MattDRT

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top