Pick the last date of the month

tanvirabid3

New Member
Joined
Oct 15, 2021
Messages
13
Office Version
  1. 365
Platform
  1. Windows
Hi everyone,
I have the daily dates for all the months of 2021. The catch is that for some months the last date is the EMONTH date like Jan 31. But for some months the last date is March 27, April 28, June 26 and so on. I want to pick the last available date for every month from Jan to Dec. Is there a way that this can be done. Thanks
 
Upvote 0
Solution

Excel Facts

Bring active cell back into view
Start at A1 and select to A9999 while writing a formula, you can't see A1 anymore. Press Ctrl+Backspace to bring active cell into view.
.. or another possibility

22 01 13.xlsm
AB
1DateLast
201-Jan-2109-Jan-21
306-Jan-2109-Jan-21
407-Jan-2109-Jan-21
508-Jan-2109-Jan-21
609-Jan-2109-Jan-21
701-Feb-2108-Feb-21
808-Feb-2108-Feb-21
901-Mar-2131-Mar-21
1031-Mar-2131-Mar-21
1104-Apr-2128-Apr-21
1222-Apr-2128-Apr-21
1328-Apr-2128-Apr-21
1402-Jun-2106-Jun-21
1506-Jun-2106-Jun-21
1614-Aug-2114-Aug-21
1712-Dec-2115-Dec-21
1815-Dec-2115-Dec-21
19
Last in month
Cell Formulas
RangeFormula
B2:B18B2=IF(TEXT(A2,"mmyy")=TEXT(A3,"mmyy"),B3,A2)

Thank you so much. Very appreciated.
 
Upvote 0

Forum statistics

Threads
1,216,100
Messages
6,128,825
Members
449,470
Latest member
Subhash Chand

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