我對UITableViewCell
用定時器填充自定義UITableViewCell?
unsigned long long seconds = milliseconds/1000;
unsigned long long minutes = seconds/60;
unsigned long long hours = minutes/60;
seconds -= minutes * 60;
minutes -= hours * 60;
NSString * result1 = [NSString `enter code here`stringWithFormat:@"%02lluH:%02lluM:%02lluS",hours,minutes,seconds];
self.menushowTime.text = result1;//populate cell label with time
具有顯示時間的問題每當我重裝表中查看我的計時器與2倍的速度運行,我的意思是非常快的。我怎樣才能防止這種情況發生。
如何是U計算毫秒? – santhu
hm = components.hour * 3600000; NSUInteger mm = components.minute * 60000; NSUInteger sm = components.second * 1000; currentTime = hm + mm + sm; NSLog(@「show current time%lld」,currentTime); 這是我如何計算 – Abhishek
和一切工作正常,面臨問題時,我開始滾動tableview或重新加載tableview – Abhishek