我正在尝试从用户输入的数字开始倒计时,但我不确定如何做到这一点。我已经对代码进行了多次尝试和更改,但没有任何区别。
我的代码:
-(IBAction)Start
{
mainInt = minutes;
Timer = [NSTimer scheduledTimerWithTimeInterval:1 target:self selector:@selector(countDown)
userInfo:nil repeats:YES];
}
我已将“分钟”声明为 UITextField,以便显示代表用户输入的数字是吗?或者没有?
我在 .m 文件中也有 @synthesised *minutes
关于我可以做些什么来使倒计时从输入到 UITextField 的数字开始的任何建议?