search

Home  >  Q&A  >  body text

objective-c - ios 时间选择器的崩溃错误

如题
Failed to allocate data stores for 10000 rows in section 0
这是崩溃抛出来的

具体指向
NSDate *maxDate = [[NSDate alloc] initWithTimeIntervalSinceNow:60 (这里有一个乘号被省略了) 60];
这一句 这是为什么 求解答

大家讲道理大家讲道理2892 days ago370

reply all(1)I'll reply

  • PHPz

    PHPz2017-04-17 18:02:38

    NSDate *maxDate = [[NSDate alloc]...,这句话是没有问题的。
    Failed to allocate data stores for 10000 rows in section 0,
    This problem is very strange. Is it because there is a problem with your even time range, causing the set maximum number of rows to be too large, and then Apple's DatePicker crashes.
    Or, is it possible that the problem is caused by incorrectly setting the DatePicker multiple times somewhere, because this bug is rare.
    Alternatively, sometimes, weird problems occur when setting up UI classes using non-main threads.

    reply
    0
  • Cancelreply