iosuitableviewaccessoryview

Change image of accessory view of a table cell


I wish to replace the icon of UITableViewCellAccessoryDetailButton with a custom icon. I have tried to replace the accessoryView with a UIButton which contains the custom image, but the button is showing like 20 pixels from the right edge of the cell.

Is there a better way to replace the icon, or to move the accessoryview all the way to the right?


Solution

  • Create a custom cell and create UIButton in the custom cell's and give the UIButton background image like "DetailButton" May this help you.