hi all
I am trying to calculate Date.Now from start Time
by using DateDiff ... here's the code
I want the output like 3,5,12
means 3 years , 5 months , 12 days
I used what ever I can to format the Interval with no result.
how can I get this, is it by DateDiff ?
any help would be appreciated
I am trying to calculate Date.Now from start Time
by using DateDiff ... here's the code
Code:
Try
Dim d1 As DateTime = CDate(DTPStartDate.Text)
Dim WD As Long = _
DateDiff("yyyymd", d1, Date.Now)
txtTotalDays.Text = WD
Catch ex As Exception
MessageBox.Show(ex.Message)
End Try
I want the output like 3,5,12
means 3 years , 5 months , 12 days
I used what ever I can to format the Interval with no result.
how can I get this, is it by DateDiff ?
any help would be appreciated