Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.newusers
|
|||
|
|||
![]() i have a list of names in one worksheet, i used a countif formula to count the number of names - but how do i replace the zero when a data is not found to somethin else such as 'error' or 'not found'?? hope someone can help -- hsb101 ------------------------------------------------------------------------ hsb101's Profile: http://www.excelforum.com/member.php...o&userid=37049 View this thread: http://www.excelforum.com/showthread...hreadid=567749 |
#2
![]()
Posted to microsoft.public.excel.newusers
|
|||
|
|||
![]()
Hi!
Try this: =IF(COUNTIF(A1:A10,"some_name"),COUNTIF(A1:A10,"so me_name"),"Not Found") Biff "hsb101" wrote in message ... i have a list of names in one worksheet, i used a countif formula to count the number of names - but how do i replace the zero when a data is not found to somethin else such as 'error' or 'not found'?? hope someone can help -- hsb101 ------------------------------------------------------------------------ hsb101's Profile: http://www.excelforum.com/member.php...o&userid=37049 View this thread: http://www.excelforum.com/showthread...hreadid=567749 |
#3
![]()
Posted to microsoft.public.excel.newusers
|
|||
|
|||
![]() i got it i think...i just used this formula... =IF(COUNTIF(A4:B45,D7),COUNTIF(A4:B45,D7),"Not Found") why does this formula work when i use the logical test being the same as the true value? -- hsb101 ------------------------------------------------------------------------ hsb101's Profile: http://www.excelforum.com/member.php...o&userid=37049 View this thread: http://www.excelforum.com/showthread...hreadid=567749 |
#4
![]()
Posted to microsoft.public.excel.newusers
|
|||
|
|||
![]()
"hsb101" wrote...
i got it i think...i just used this formula... =IF(COUNTIF(A4:B45,D7),COUNTIF(A4:B45,D7),"Not Found") why does this formula work when i use the logical test being the same as the true value? The logical test: COUNTIF(A4:B45,D7), will return a number, either 0 or some number greater than 0. When it returns 0 the logical test evaluates to FALSE and the formula returns "Not Found". When the logical test returns ANY number other than 0 then the logical test evaluates to TRUE and performs the second Countif. It can also be expressed as: =IF(COUNTIF(A4:B45,D7)0,COUNTIF(A4:B45,D7),"Not Found") But my version saves 2 keystrokes and and 1 evaluation step! <g Biff |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
have some problem with database | Excel Discussion (Misc queries) | |||
Urgent Help Required on Excel Macro Problem | Excel Discussion (Misc queries) | |||
Problem With Reference Update | Excel Worksheet Functions | |||
Copy an Drag cell Formula Problem | Excel Discussion (Misc queries) | |||
Freeze Pane problem in shared workbooks | Excel Discussion (Misc queries) |