用label获取动态时间

NSDateFormatter *Dateformat = [[NSDateFormatter alloc]init];

[Dateformat setDateFormat"DD-MM-YYYY"];

NSMutableString *DateStr = [Dateformat stringFromDate:StrDate];

[UserCntrl.timeDisplay setText:DateStr];

[Dateformat setDateFormat"HH:MM"];

NSMutableString *timeStr=[Dateformat stringFromDate:StrDate];

你可能感兴趣的:(label)