![]() |
Validation - Weekend Or text
Hi, I'm trying to validate cell D1 so only weekend dates are approved *or* the text Paid. I have tried this in the custom formula box: =OR(WEEKDAY(D1,2)5,D1="Paid") This accepts weekend dates but for some reason won't accept the text Paid. What am I doing wrong? -- jnk101 ------------------------------------------------------------------------ jnk101's Profile: http://www.excelforum.com/member.php...o&userid=27521 View this thread: http://www.excelforum.com/showthread...hreadid=470377 |
Hi!
The problem is that if D1 = paid (or any text value for that matter), it causes the WEEKDAY function to error with #VALUE!. Try this: =OR(TEXT(D1,"ddd")="Sat",TEXT(D1,"ddd")="Sun",D1=" Paid") Biff "jnk101" wrote in message ... Hi, I'm trying to validate cell D1 so only weekend dates are approved *or* the text Paid. I have tried this in the custom formula box: =OR(WEEKDAY(D1,2)5,D1="Paid") This accepts weekend dates but for some reason won't accept the text Paid. What am I doing wrong? -- jnk101 ------------------------------------------------------------------------ jnk101's Profile: http://www.excelforum.com/member.php...o&userid=27521 View this thread: http://www.excelforum.com/showthread...hreadid=470377 |
Hi,
Try this =OR(WEEKDAY(D1,2)5,"Paid") Regards, Ashish Mathur "jnk101" wrote: Hi, I'm trying to validate cell D1 so only weekend dates are approved *or* the text Paid. I have tried this in the custom formula box: =OR(WEEKDAY(D1,2)5,D1="Paid") This accepts weekend dates but for some reason won't accept the text Paid. What am I doing wrong? -- jnk101 ------------------------------------------------------------------------ jnk101's Profile: http://www.excelforum.com/member.php...o&userid=27521 View this thread: http://www.excelforum.com/showthread...hreadid=470377 |
That doesn't work in DV, it errors on input. See Biff's reply for a working
solution. -- HTH Bob Phillips "Ashish Mathur" wrote in message ... Hi, Try this =OR(WEEKDAY(D1,2)5,"Paid") Regards, Ashish Mathur "jnk101" wrote: Hi, I'm trying to validate cell D1 so only weekend dates are approved *or* the text Paid. I have tried this in the custom formula box: =OR(WEEKDAY(D1,2)5,D1="Paid") This accepts weekend dates but for some reason won't accept the text Paid. What am I doing wrong? -- jnk101 ------------------------------------------------------------------------ jnk101's Profile: http://www.excelforum.com/member.php...o&userid=27521 View this thread: http://www.excelforum.com/showthread...hreadid=470377 |
All times are GMT +1. The time now is 12:45 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com