Stopwatch.IsRunning 属性

定义

获取一个指示 Stopwatch 计时器是否在运行的值。Gets a value indicating whether the Stopwatch timer is running.

public:
 property bool IsRunning { bool get(); };
public bool IsRunning { get; }
member this.IsRunning : bool
Public ReadOnly Property IsRunning As Boolean

属性值

如果 Stopwatch 实例当前正在运行,并且在对某个时间间隔的运行时间进行测量,则该值为 true;否则为 falsetrue if the Stopwatch instance is currently running and measuring elapsed time for an interval; otherwise, false.

注解

实例通过Start调用或StartNew开始运行。 StopwatchA Stopwatch instance begins running with a call to Start or StartNew. 实例通过调用StopReset停止运行。The instance stops running with a call to Stop or Reset.

适用于

另请参阅