TEXTJOIN - IF AND Query

ChrisM92

New Member
Joined
Nov 4, 2020
Messages
21
Office Version
  1. 2019
Platform
  1. Windows
Hi,

I've got a TEXTJOIN formula to create a consolidated list of all fields with a date between 2 given dates.
It seemed to work when I first put it in and suddenly stopped and now I can't get it back ?

Any idea where I'm going wrong? Below is a simplified version of my sheet (The live one has 80 fields)

="◆"&TEXTJOIN(CHAR(10)&"◆",TRUE,IF(AND($E3:$H3>=J$1,$E3:$H3<=J$2),$E$1:$H$1,""))

1622813985132.png
 

Excel Facts

Excel motto
Not everything I do at work revolves around Excel. Only the fun parts.
Try it like
Excel Formula:
="◆"&TEXTJOIN(CHAR(10)&"◆",TRUE,IF(($E3:$H3>=J$1)*($E3:$H3<=J$2),$E$1:$H$1,""))
 
Upvote 0
Solution
Thank you very much Fluff! Works perfectly with that

Any reason why that works but not the other so I know for next time?
 
Upvote 0
When using arrays you should always use
Excel Formula:
($E3:$H3>=J$1)*($E3:$H3<=J$2)
instead of And, or
Excel Formula:
($E3:$H3>=J$1)+($E3:$H3<=J$2)
instead of Or.
 
Upvote 0
You're welcome & thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,214,979
Messages
6,122,550
Members
449,088
Latest member
davidcom

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top