Home |
Search |
Today's Posts |
#2
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
A logical expression returns with TRUE or FALSE (Boolean values); put a
number in A1 and try this formula =A15 When you perform an arithmetic operation on a Boolean Value, Excel treats TRUE as 1 and FALSE as zero Try =2*(A15) So to keep just 1 or zero we could multiple by 1: =1*(A15) Or we could negate the value twice =-(A15) returns with -1 or 0 while =--(A15) will return either 1 or 0 In short, the double negation is the more efficient way to coerce Boolean values to numeric values 1/0 For more read these http://www.xldynamic.com/source/xld.SUMPRODUCT.html http://mcgimpsey.com/excel/formulae/doubleneg.html best wishes -- Bernard V Liengme www.stfx.ca/people/bliengme remove caps from email "WLMPilot" wrote in message ... I spotted this in a questions and want to know what the dashes are for. I have also seen dashes used in the SUMPRODUCT function. This is copied & pasted to show entire question/answer QUESTION: =IF(AND(A4="4/12/2006",A4<="9/12/2006"),"49") This should show next week as 'Week 49' but doesn't. I want to add another three IF to this string so that I can get the month sorted out in Week order? ANSWER: Try it as: =IF(AND(A4=--"4/12/2006",A4<=--"9/12/2006"),49) |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Removing dashes from ISBN's while still keeping 1st number (zero) | Excel Worksheet Functions | |||
How do I add a 0 and 2 dashes to a truncated soc. sec.# in a cell | Excel Discussion (Misc queries) | |||
Stripping the dashes | Excel Discussion (Misc queries) | |||
Dashes in Functions | Excel Discussion (Misc queries) | |||
How to insert a repeating dash in phone numbers without dashes in. | New Users to Excel |