Partager via


TimeSpan.FromTicks Method

Returns a TimeSpan object (time period) that is equivalent to a specified number of ticks.

Namespace: System
Assembly: mscorlib (in mscorlib.dll)

Syntax

public static TimeSpan FromTicks (
         long val
)

Parameters

  • val
    A number of ticks that specifies a time.

Return Value

A TimeSpan object that is equivalent to the specified number of ticks.

Version Information

Available in the .NET Micro Framework versions 2.0, 2.5, 3.0, 4.0, 4.1, and 4.2.

See Also

Reference

TimeSpan Structure
TimeSpan Members
System Namespace