C# TimeSpan Seconds
Description
TimeSpan Seconds
gets the seconds component of the time
interval represented by the current TimeSpan structure.
Syntax
TimeSpan.Seconds
has the following syntax.
public int Seconds { get; }
Example
The following example creates several TimeSpan objects and displays the Seconds property of each.
using System;/*from w w w . j a v a 2 s .co m*/
class TimeSpanPropertiesDemo
{
static void Main( )
{
TimeSpan ts = new TimeSpan( 98712345678 );
Console.WriteLine(ts.Seconds);
}
}
The code above generates the following result.