i need to do something on accessoryType
click in tableview in iphone.how can i find accessoryType
click in UITableView
in iphone.
you need to define the accessoryType
of the cell in the
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
like this
cell.accessoryType = UITableViewCellAccessoryDetailDisclosureButton;
the method for row selection of this accessoryType is
- (void)tableView:(UITableView *)tableView accessoryButtonTappedForRowWithIndexPath:(NSIndexPath *)indexPath
but if you are defining any other accessoryType for cell than you can use this method.
- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
use this delegate method for this purpose
- (void)tableView:(UITableView *)tableView accessoryButtonTappedForRowWithIndexPath:(NSIndexPath *)indexPath
This fires when you click on accessory
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With