System::Threading::Timer::Change 方法

Timer::Change(int64_t, int64_t) method

重新调度或取消计时器。

bool System::Threading::Timer::Change(int64_t dueTime, int64_t period)
参数类型描述
dueTimeint64_tTimeout 在下一次调用回调函数之前的时间(毫秒);负值即使计时器已被调度也会取消计时器。
periodint64_tTimeout 在回调函数连续调用之间的时间(毫秒);非正值表示计时器只会执行一次。

另见

Timer::Change(System::TimeSpan, System::TimeSpan) method

重新调度或取消计时器。

bool System::Threading::Timer::Change(System::TimeSpan dueTime, System::TimeSpan period)
参数类型描述
dueTimeSystem::TimeSpanTimeout 在下一次调用回调函数之前的时间;负值即使计时器已被调度也会取消计时器。
periodSystem::TimeSpanTimeout 在回调函数连续调用之间的时间;非正值表示计时器只会执行一次。

另见