为什么Vote();
函数不能在此计时器中运行?为什么函数不在这个定时器内运行?
消息框一个作品,但投一个没有
public void Timer()
{
var timespan = new TimeSpan(0, 0, 20);
var timer = new System.Timers.Timer(timespan.TotalMilliseconds);
timer.Elapsed += (o, e) =>
{
MessageBox.Show("Worked");
Vote();
};
timer.Start();
}
投票是这样的代码中此功能,感谢,奥利弗以上。
提供'投票()'函数的代码。 – 2012-02-27 05:48:44
当你点击'MessageBox'的Ok'时它会运行吗? – V4Vendetta 2012-02-27 05:49:00
是V4和Sai:http://pastebin.com/f1yKBCAH – user1233208 2012-02-27 05:53:17