Pull in the last day of the year based on text

FredFlamingo

New Member
Joined
Apr 24, 2020
Messages
8
Platform
  1. Windows
Hi all,

I need help with a formula, I need it to pull in the last day of the year when it looks up to a certain string of text... e.g. if it says ABC Ltd or ABC LTD International i want it to pull in 12/31/2020 otherwise any other company name it will pull in today's date. i know there is an EOmonth Formula which pulls in the end of the month but there doesn't appear to be the equivalent for end of year. i have pasted the formula i have so far below (i have removed pathways and names of files)

=IFERROR(IF(VLOOKUP(C2,.xlsx]FILE NAME'!$A:$E,5,FALSE)=("ABC Ltd"),(EOMONTH(TODAY(),0)),IF(VLOOKUP(C2,.xlsx]FILE NAME'!$A:$E,5,FALSE)=("ABC LTD International"),(EOMONTH(TODAY(),0)),(TODAY()))),TODAY())
 

Excel Facts

Format cells as currency
Select range and press Ctrl+Shift+4 to format cells as currency. (Shift 4 is the $ sign).
Perhaps the date function can help you. DATE(YEAR(TODAY()),12,31)
 
Upvote 0

Forum statistics

Threads
1,223,896
Messages
6,175,264
Members
452,627
Latest member
KitkatToby

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