ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Reference Date with Or Function (https://www.excelbanter.com/excel-discussion-misc-queries/119118-reference-date-function.html)

rac

Reference Date with Or Function
 
I'm trying to use an Or() function to reference a cell which is formated
as a date. I get an error every time I try.

If(OR(A2={B2,B6}),"text","")

A2, B2 and B6 are all dates.


rac

Niek Otten

Reference Date with Or Function
 
=IF(OR(A2=B2,A2=B6)),"text","")

--
Kind regards,

Niek Otten
Microsoft MVP - Excel

"rac" wrote in message ...
| I'm trying to use an Or() function to reference a cell which is formated
| as a date. I get an error every time I try.
|
| If(OR(A2={B2,B6}),"text","")
|
| A2, B2 and B6 are all dates.
|
|
| rac



Gord Dibben

Reference Date with Or Function
 
=IF(OR(A2=B2,(A2=B6)),"text","")


Gord Dibben MS Excel MVP

On Thu, 16 Nov 2006 16:33:00 -0500, rac wrote:

I'm trying to use an Or() function to reference a cell which is formated
as a date. I get an error every time I try.

If(OR(A2={B2,B6}),"text","")

A2, B2 and B6 are all dates.


rac



rac

Reference Date with Or Function
 
Gord Dibben wrote:
=IF(OR(A2=B2,(A2=B6)),"text","")


Gord Dibben MS Excel MVP

On Thu, 16 Nov 2006 16:33:00 -0500, rac wrote:

I'm trying to use an Or() function to reference a cell which is formated
as a date. I get an error every time I try.

If(OR(A2={B2,B6}),"text","")

A2, B2 and B6 are all dates.


rac




Thanks Much! It seems so simple now.

rac

Teethless mama

Reference Date with Or Function
 
You have a correct formula. All you have to commit ctrl+shift+enter (not just
enter)


"rac" wrote:

I'm trying to use an Or() function to reference a cell which is formated
as a date. I get an error every time I try.

If(OR(A2={B2,B6}),"text","")

A2, B2 and B6 are all dates.


rac



All times are GMT +1. The time now is 06:34 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com