Horizontal Scroll in TableViewCell

Discussion in 'iOS Programming' started by erosenba, Aug 26, 2009.

  1. erosenba macrumors newbie

    Joined:
    Aug 12, 2009
    #1
    Hi,

    I'm creating an app where I will be displaying data in a tableview. I need to be able to show a variable amount of data which is stored in a mutable array (I was thinking in the forms of labels) and have it all in one cell. The table itself also needs to scroll vertically. I currently am loading the cells from a nib file but I can change that if need be. Any suggestions on how to implement some kind of horizontal scrolling or how to display the data would be really appreciated.

    Thanks,
    Erin
     
  2. dejo Moderator

    dejo

    Staff Member

    Joined:
    Sep 2, 2004
    Location:
    The Centennial State
    #2
    I would go with multi-line labels and then adjust the height of each row based on its content.
     
  3. erosenba thread starter macrumors newbie

    Joined:
    Aug 12, 2009
    #3
    UPDATE: I figured it out. Just add the UIScrollView to the cell in IB with a tag. In the cellForRowAtIndexPath method access the scrollview through the viewWithTag method and then set the contentsize and add any subviews you'd like.
     

Share This Page