![]() |
![]() |
|
|||||||
| Excel Questions All Excel/VBA questions - formulas, macros, pivot tables, general help, etc. Please post to this forum in English only. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
New Member
Join Date: May 2002
Posts: 2
|
I'm trying to figure out how to calculate the eligibility date for employees. The data would be the Date of Hire, eligibility starts 30 days follwing date of hire on the first of the following month.
Example: Date of Hire - 01/15/2002 (this is the constant) Eligible - 03/01/2002 (this is what the results of the formula should show) I'd appreciate any help! DW in OKC [ This Message was edited by: DW in OKC on 2002-05-20 14:39 ] |
|
|
|
|
|
#2 |
|
Board Regular
Join Date: Feb 2002
Location: Southfield,MI USA
Posts: 1,030
|
Hey,
How about: =EOMONTH(A2,1)+1 (where A2 holds the hiredate) Adam |
|
|
|
|
|
#3 |
|
MrExcel MVP
Join Date: May 2002
Posts: 13,278
|
DW,
Try the following: =DATEVALUE("01"&"/"&(MONTH(EOMONTH(A1,2)))&"/"&(YEAR(EOMONTH(A1,2)))) Hope this helps, Paddy |
|
|
|
|
|
#4 |
|
MrExcel MVP
Join Date: Mar 2002
Location: Michigan USA
Posts: 11,452
|
or how about
=IF((EOMONTH(A3,0)+1-A3)<30,EOMONTH(A3,1)+1,EOMONTH(A3,0)+1)
__________________
Regards! Yogi Anand, D.Eng, P.E. Energy Efficient Building Network LLC www.energyefficientbuild.com |
|
|
|
|
|
#5 |
|
New Member
Join Date: May 2002
Posts: 2
|
The winner is Yogi Anand,ANAND Enterprises. Thanks for everyone's help. I tried all three answers and the best fit was Yogi's. This will make a client very happy!
Maybe I can help the next person that needs help! DW [ This Message was edited by: DW in OKC on 2002-05-20 14:59 ] |
|
|
|
|
|
#6 |
|
MrExcel MVP
Join Date: Mar 2002
Location: Michigan USA
Posts: 11,452
|
Hi DW in OKC:
I am glad the solution that we folks at MrExcel developed for you worked out. Please keep in mind, we are not competing here -- all of us complement and feed off each other. When a solution works out, thanks should go to all those who participated in developing the solution. And when a solution works out we are all winners -- not a single individual. So, I hope you will join me in thanking all of the folks who worked with you in developing this solution. So, thanks go to the whole team: DW, Adam, Paddy, and Yogi. Regards! |
|
|
|
|
|
#7 |
|
MrExcel MVP
Join Date: Feb 2002
Location: Austin, Texas USA
Posts: 11,654
|
Okay, but what if the date of hire is 1/30/02? If "eligibility starts 30 days following date of hire on the first of the following month" then ="1/30/02"+30 is 3/1/02, and the "first of the following month" is 4/1/02.
The formula, =EDATE(TEXT(A2+30,"m-yyyy")+0,1), produces 4/1/02. [ This Message was edited by: Mark W. on 2002-05-20 15:59 ] |
|
|
|
|
|
#8 |
|
MrExcel MVP
Join Date: Mar 2002
Location: Michigan USA
Posts: 11,452
|
Hi Mark:
That's beautiful ... also short and sweet. Regards! |
|
|
|
![]() |
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|