Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to detect that UITableView is in editing mode?

I have a situation in which I am putting the UITableView in editing mode, and when it is not in editing mode, it has to perform tableview: didSelectRowAtIndexPath: and has to be pushed on a UINAvigationController.

Now the problem is that how can I check that whether the UITableView is in editing mode so that it should not be pushed over UINavigationController.

like image 596
Hassam Avatar asked Mar 30 '12 07:03

Hassam


3 Answers

editing

A Boolean value that determines whether the receiver is in editing mode.

@property(nonatomic, getter=isEditing) BOOL editing

i.e. [tableView isEditing] == YES

like image 88
Alexander Avatar answered Nov 05 '22 11:11

Alexander


There is a property editing on your tableView, check if it's YES or NO.

like image 41
Mat Avatar answered Nov 05 '22 12:11

Mat


check this

if (yourtableview.isEditing == YES) { //do something }

like image 21
Piyush Kashyap Avatar answered Nov 05 '22 12:11

Piyush Kashyap