Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
How can I format a cell to display a "Y" or "N" when a value of 1 or 0 is
entered? |
#2
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
You can't. But right click sheet tabview codeinsert this.
Now if you are in the specified range you will get what you want Private Sub Worksheet_Change(ByVal Target As Range) If Not Intersect(Target, Range("a2:a22")) Is Nothing Then If Target = 1 Then Target = "Y" If Target = 0 Then Target = "N" End If End Sub -- Don Guillett SalesAid Software "Brad" wrote in message ... How can I format a cell to display a "Y" or "N" when a value of 1 or 0 is entered? |
#3
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
CUSTOM format cell as "Y";;"N"
HTH "Brad" wrote: How can I format a cell to display a "Y" or "N" when a value of 1 or 0 is entered? |
#4
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Let me clarify further. How do I prevent someone from entering anything
other than a 1 or 0? In other words, I want a 1 entered so the cell displays a "Y" or I want a 0 entered so the cell displays a "N". All other options should be invalid. "Toppers" wrote: CUSTOM format cell as "Y";;"N" HTH "Brad" wrote: How can I format a cell to display a "Y" or "N" when a value of 1 or 0 is entered? |
#5
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
I just learned a new one but it does Y for anything above 1 also.
-- Don Guillett SalesAid Software "Toppers" wrote in message ... CUSTOM format cell as "Y";;"N" HTH "Brad" wrote: How can I format a cell to display a "Y" or "N" when a value of 1 or 0 is entered? |
#6
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
You could use Data Validation with list of 0,1 plus formatting as per
previous reply. "Brad" wrote: Let me clarify further. How do I prevent someone from entering anything other than a 1 or 0? In other words, I want a 1 entered so the cell displays a "Y" or I want a 0 entered so the cell displays a "N". All other options should be invalid. "Toppers" wrote: CUSTOM format cell as "Y";;"N" HTH "Brad" wrote: How can I format a cell to display a "Y" or "N" when a value of 1 or 0 is entered? |
#7
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
That works. Thanks!
"Toppers" wrote: You could use Data Validation with list of 0,1 plus formatting as per previous reply. "Brad" wrote: Let me clarify further. How do I prevent someone from entering anything other than a 1 or 0? In other words, I want a 1 entered so the cell displays a "Y" or I want a 0 entered so the cell displays a "N". All other options should be invalid. "Toppers" wrote: CUSTOM format cell as "Y";;"N" HTH "Brad" wrote: How can I format a cell to display a "Y" or "N" when a value of 1 or 0 is entered? |
#8
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
DataValidationAllowWhole Number
Minimum.....0 Maximum.....1 The do the formatting as Toppers suggests. Gord Dibben MS Excel MVP On Thu, 8 Feb 2007 09:09:01 -0800, Brad wrote: Let me clarify further. How do I prevent someone from entering anything other than a 1 or 0? In other words, I want a 1 entered so the cell displays a "Y" or I want a 0 entered so the cell displays a "N". All other options should be invalid. "Toppers" wrote: CUSTOM format cell as "Y";;"N" HTH "Brad" wrote: How can I format a cell to display a "Y" or "N" when a value of 1 or 0 is entered? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
format cells to display 20 long sentences in a single cell | Excel Discussion (Misc queries) | |||
Can I format a cell to display latitude and longitude | Excel Discussion (Misc queries) | |||
how to format a cell to display October 21st, 2006 | Excel Worksheet Functions | |||
Copy cell format to cell on another worksht and update automatical | Excel Worksheet Functions | |||
Format a cell to display decimal hours. | Excel Discussion (Misc queries) |