Hai all,

I am attaching an excel userform which contains Dateof Birth textbox and
Date of Retirement textbox.

Conditions are:

i) Date of Retirement should be 60 years after Date of Birth
eg. if date of birth is in the year 1960 date of retirement would be 2020

ii) Date of retirement would be last  day of the month

if date of birth is on 28-04-1981 then date of retirement would in the last
day of the April month i.e. 30-04-2041

iii) if the date of retirement falls in the month of February and if it is a
leap year then the retirement date would be 29th feb.

iv) If date of birth fells on 1st of the month the retirement date would be
the last day of the last month
eg. if Dob is 01-01-2012 then the date of retirement would be 31-12-2011.

I have written code for that but its not throwing errors.  if there is any
simplest way may kindly be suggest.

-- 
----------------------------------------------------------------------------------
Some important links for excel users:
1. Follow us on TWITTER for tips tricks and links : 
http://twitter.com/exceldailytip
2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310
3. Excel tutorials at http://www.excel-macros.blogspot.com
4. Learn VBA Macros at http://www.quickvba.blogspot.com
5. Excel Tips and Tricks at http://exceldailytip.blogspot.com
 
To post to this group, send email to excel-macros@googlegroups.com

<><><><><><><><><><><><><><><><><><><><><><>
Like our page on facebook , Just follow below link
http://www.facebook.com/discussexcel

Attachment: dOr.xls
Description: MS-Excel spreadsheet

Reply via email to