![]() |
|
#1
|
|||
|
|||
Date Difference / Years and Months ElapsedCan anyone guide me as to how to display on a text box the number of years and months that have past between today and the date from a calendar datepicker placed on a form from which the user will select the account opening date. I want display on the text box "This account is x years and x months old".
Here is the code that I am using, but of course is incomplete. Please correct it accordingly. Thanks. VB / Visual Basic Code:
Last edited by admin : 04-Sep-2008 at 05:41.
Reason: Please insert your example VB codes between [VB] and [/VB] tags
|
|
#2
|
|||
|
|||
Re: Date Difference / Years and Months ElapsedCan you not use DateDiff in VB.Net?
DateDiff("yyyy", DateTimePicker1.Value, DateTime.Today) for years Using "m" for months? |
Recent GIDBlog
Writing a book by crystalattice
| Thread Tools | Search this Thread |
| Rate This Thread | |
|
|
Network Sites: GIDNetwork · GIDWebHosts · GIDSearch · Learning Journal by J de Silva, The