# Formula Help

#### CARBOB

##### Well-known Member
The values in AF:AJ are custom formatted, "00". I need a formula in columns AK:AO that returns MDN, if the value is one odd/ one even; return DOD, if the value is two odd digits; return DEV, if the value is two even digits.
Excel Workbook
AFAGAHAIAJAKALAMANAO
10714242733MDNMDNDEVMDNDOD
22529303335MDNMDNMDNDODDOD
30612152227DEVMDNDODDEVMDN
40517232432MDNDODMDNDEVMDN
Sheet4
Excel 2007

### Excel Facts

Copy a format multiple times
Select a formatted range. Double-click the Format Painter (left side of Home tab). You can paste formatting multiple times. Esc to stop
So, is the entry in AF1

07 or 7 ?

what should happen when 1 digit is 0?

So, is the entry in AF1

07 or 7 ?

A 7 custom formatted to show 07 as 2 digits, "00"

Last edited:
what should happen when 1 digit is 0?

The digits range from 1-36. Digits 1-9 custom formatted "00", to show as 2 digits. Digits 2,4,6,8 = DEV;DIGITS 1,3,5,7,9 =DOD

Last edited:
put this in AK1 and fill right and down:

=CHOOSE(IF(MOD(AF1,2),1,2)+IF(MOD(INT(AF1/10),2),1,2),,"DOD","MDN","DEV")

let us know

put this in AK1 and fill right and down:

=CHOOSE(IF(MOD(AF1,2),1,2)+IF(MOD(INT(AF1/10),2),1,2),,"DOD","MDN","DEV")

let us know

Works like a charm, thank you very much!!!

Replies
4
Views
183
Replies
4
Views
362
Replies
1
Views
55
Replies
4
Views
411
Replies
1
Views
111

1,216,130
Messages
6,129,058
Members
449,484
Latest member
khairianr

### 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.

### Which adblocker are you using?

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

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