【问题标题】:How set accessory type when tabel view is enbled to editing?启用表格视图进行编辑时如何设置附件类型?
【发布时间】:2010-05-06 10:11:40
【问题描述】:

我正在使用 UITableView 属性对其进行编辑。 theTableView.editing = YES; theTableView.allowsSelectionDuringEditing = YES;

它工作正常,该行被选中,我正在进入下一个控制器,但我需要在该行中显示附件类型。我正在使用下面的行,但即使它不起作用。 是否有任何属性或缺少任何东西来显示该指标。

cell.accessoryType = UITableViewCellAccessoryDisclosureIndicator;

我正在使用下面的代码进行表格视图。

theTableView = [[UITableView alloc] initWithFrame:tableRect style:UITableViewStyleGrouped]; 
theTableView.editing = YES;
theTableView.allowsSelectionDuringEditing = YES;
theTableView.delegate = self;
theTableView.dataSource = self;
theTableView.scrollEnabled=YES;
theTableView.separatorColor = [UIColor lightGrayColor];
theTableView.autoresizingMask=YES;
theTableView.allowsSelection=YES;
theTableView.sectionHeaderHeight=5;
theTableView.sectionFooterHeight=5;

[myView addSubview:theTableView];

请帮帮我。

谢谢你, 马丹·莫汉

【问题讨论】:

    标签: objective-c uitableview indicator


    【解决方案1】:

    您可以使用 UITableViewCell 类的editingAccessoryType 属性。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2017-06-30
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多