zoukankan      html  css  js  c++  java
  • Error Set

    1、

    reason: '[<CTXCourseDetailViewController 0x6db4010> setValue:forUndefinedKey:]: this class is not key value coding-compliant for the key tableview.'

    原因:删除了原来在Storyboard中的 Table View 在 CTXCourseDetailViewController 中的Outlet ‘tableview’。

    2、在Storyboard中,在View Controller 中添加 Table View

    *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: '-[UITableViewController loadView] loaded the "4Kh-Te-V59-view-z5E-sD-s1e" nib but didn't get a UITableView.'

    原因:在对应的控制器 CTXCourseDetailViewController  中,CTXCourseDetailViewController  错误地继承了 UITableViewController 的自定义子类。应继承自 UIViewController。

    3、调试时,Xcode死了,强行关闭重启并运行后报错:

    1 Couldn't register com.Submarinex.App with the bootstrap server. Error: unknown error code.
    2 This generally means that another instance of this process was already running or is hung in the debugger.(lldb) 

    解决:重启电脑。

    4、在新增course的model segue后,在viewDidLoad方法中设置 self.editing = YES; 报错

    1 2012-10-26 19:24:01.669 CT[381:fb03] *** Assertion failure in -[UITableView _endCellAnimationsWithContext:], /SourceCache/UIKit_Sim/UIKit-1914.84/UITableView.m:1037
    2 2012-10-26 19:24:01.758 CT[381:fb03] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Invalid update: invalid number of rows in section 0.  The number of rows contained in an existing section after the update (1) must be equal to the number of rows contained in that section before the update (1), plus or minus the number of rows inserted or deleted from that section (1 inserted, 0 deleted) and plus or minus the number of rows moved into or out of that section (0 moved in, 0 moved out).'

    在我的project中,解决方法:在 self.editing = YES; 之前添加 [self.tableView reloadData];。

    原因:tableview 最初没有关于数据源和委托的信息。所以需要 reloadData 最为初始化的一部分。

  • 相关阅读:
    DHCP服务器
    继承、抽象、多态
    范围随机数Random
    阿里、北理工、清华以及华为的镜像站
    创建kafka生产对象
    kafka消费者的配置
    Kafka 流数据 SQL 引擎 -- KSQL
    认证maven工程
    基础算法
    Java基础
  • 原文地址:https://www.cnblogs.com/submarinex/p/2687767.html
Copyright © 2011-2022 走看看