custom number format

sareehy

New Member
Joined
Oct 16, 2024
Messages
1
Office Version
  1. 2010
Platform
  1. Windows
Hi,

Can i customize number format as the following:

If I type 1 it will display "ELC"
If I type 2 it will display "AC"
if i type 0 it will display "plm"
 

Excel Facts

What is the last column in Excel?
Excel columns run from A to Z, AA to AZ, AAA to XFD. The last column is XFD.
Welcome to the Board!

Custom number formats usually break up the numbers into three categories, negative, positive, and zeroes. I do not know of a way you can do what you want for specific numbers using a Custom Number format.

I would probably opt for a lookup table, or VBA code do what you want (the VBA code can be created to run automatically upon manual cell updating).
If you are agreeable to a VBA solution, what range of cells would you want to apply this to?
 
Upvote 0
Hi

[=1]"ELC";[=2]"AC";"plm";@
Did you try it?
It doesn't work for me. It returns the value I type into the cell and doesn't change anything.
 

Attachments

  • 1729108839912.png
    1729108839912.png
    1.2 KB · Views: 1
Upvote 0
HI

[=1]"ELC";[=2]"AC";"plm"
I honestly didn't know you could do this, so consider me educated.
That seems to work a little better, but still has issues.
If you enter anything other than 0,1, or 2, it will return "plm".
 
Upvote 0
Hi

Alternatively by creating 4 rules, with conditional formatting
 
Upvote 0

Forum statistics

Threads
1,223,896
Messages
6,175,259
Members
452,626
Latest member
huntinghunter

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