Sixem

.NET Time Since Date

Jul 30th, 2013
129
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
VB.NET 0.32 KB | None | 0 0
  1. Dim DSD_KB = Math.Round(CInt((DateTime.UtcNow - New DateTime(2012, 7, 18, 0, 0, 0)).TotalSeconds), 0)
  2. Dim DSD_Span As TimeSpan = TimeSpan.FromSeconds(DSD_KB)
  3. Date_Since_Dawn.Text = String.Format("{0} Days {1} Hours {2} Minutes {3} Seconds", DSD_Span.Days,                DSD_Span.Hours, DSD_Span.Minutes, DSD_Span.Seconds)
Advertisement
Add Comment
Please, Sign In to add comment