dates quandry with <> and MID

IanWells

Board Regular
Joined
Apr 2, 2003
Messages
86
Hi All

Struggling a little here with a formula and hope you can help...

the formula below may self explain but please ask if it doesnt, i know its wrong but sure its the right lines....

=networkdays(if(D18>(mid(L1,2,12))),(E18<(mid(M1,2,12)))

Im trying to get the networkdays count between dates using L1 (but if D18 is greater use that date) and M1 (but if E18 is before use that date).

The MID must be used in L1 & M1

Thanks in anticipation.

Ian
 

Excel Facts

Does the VLOOKUP table have to be sorted?
No! when you are using an exact match, the VLOOKUP table can be in any order. Best-selling items at the top is actually the best.
Thanks Richard.

Thats just what i needed...

Excellent

Thanks again.

I need a countifs formula based on the dates quandry also, shall i create a new thread or is it ok to proceed on this one if its ok with you?

Ian
 
Upvote 0
Right here goes.....

i am using this formula..

=COUNTIFS(Data!A:A,'Diary Report'!A3,Data!L:L,N$1,Data!L:L,O$1)

N1 and O1 contains the dates with < & > (eg <01/01/2011) preceeding each, Now lets say in A1 and B1 we have More dates without < & > (01/01/2011).

I need the above formula to incorporate the latest date between A1 and N1 and the oldest date between B1 and O1.

Hope i've explained ok.

cheers

Ian
 
Upvote 0
Maybe you could answer this question a little easier.

If i use the MAX and MIN to ascertain the greater and lower! Why when i use the COUNTIFS if formula it doesnt seem to recognise the MAX and MIN date shown?...

Ian
 
Upvote 0
You need to structure it like in the following (note actual dates are contained in the cells A1 and N1 and B1 and O1 (not a string like ">20/8/2011"):

=COUNTIFS(Data!A:A,'Diary Report'!A3,Data!L:L,"<" & MAX(N$1,$A$1),Data!L:L,">" & MIN(O$1,$B$1))
 
Upvote 0
Richard

Thanks very much for your time, i've achieved my goal a slightly different way now but your guidence was a big big help.

I used the MAX (I10) and MIN (J10) to get the dates i needed then used

=COUNTIFS(Data!A:A,'Diary Report'!A10,Data!L:L,">"&I10,Data!L:L,"<"&J10)

Thanks again, another fantastic help for me from mrexcel.com

best regards

Ian
 
Upvote 0

Forum statistics

Threads
1,224,507
Messages
6,179,183
Members
452,893
Latest member
denay

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