Where to find UITableViewCell configure button

Discussion in 'iPhone/iPad Programming' started by RossOliver, Apr 13, 2008.

  1. macrumors regular

    Joined:
    Nov 6, 2006
    #1
    Hey,

    In interface builder when you drag a UITableViewCell onto a view you can set the button displayed at the right of the cell to 'Configure button'.

    Is this a predefined button available in XCode or is it just in Interface Builder? If it's just in IB then is there a way to get my hands on it to use in my XCode custom UITableViewCell?

    Thanks for your time,

    -Ross
     
  2. thread starter macrumors regular

    Joined:
    Nov 6, 2006
    #2
    Typical, I just found it is a preset:

    Code:
    cell.accessoryType = UITableViewCellAccessoryDetailDisclosureButton;
    
    Never mind :rolleyes:
     
  3. thread starter macrumors regular

    Joined:
    Nov 6, 2006
    #3
    Hmm, now I have my configure button, but I can't get the accessoryAction property to work:

    Code:
    cell.accessoryAction = @selector( someAction );
    
    This should call the someAction method (in the same module) but it doesn't appear to... any ideas?

    Thanks,

    -Ross
     
  4. macrumors 6502a

    Joined:
    Jul 17, 2008
    Location:
    Seattle, WA
    #4
    I have this same problem. Anyone have any idea on how to make that chevron icon work?
     
  5. macrumors newbie

    Joined:
    Jun 28, 2008
    #5
    Getting problem in creating coloumns and headers

    Hi Guys,

    I am new in devlopment. Please tell me how can i add header in UITableView class and i hav to always add label for showing txt in columns or is there any other way. Tell me how can i bind multiple column datasource to this UITableView object.Tell me how can i handle single click event on particular cell i am able to capture it but for only selected row not cell. indexPath.Section always come zero.

    Thanks in advance

    Gagan
     
  6. macrumors 68030

    PhoneyDeveloper

    Joined:
    Sep 2, 2008
    #6
    In order for an action to work you also need a target, which is the object that the action message will be sent to. Typically an action method takes a single parameter so the selector has a colon at the end.

    So in your tableview controller you might have code like this

    Code:
    cell.target = self;
    cell.accessoryAction = @selector(theAction:);
    If you have a table and just want to see the chevron and then respond to a row being selected instead you should just implement these delegate methods:

    tableView:accessoryTypeForRowWithIndexPath:
    tableView:commitEditingStyle: forRowAtIndexPath:
     

Share This Page