uitableviewcell

Adding a row of icons to a table cell.

Okay I am just totally too close to this I think. I have a tableview. In that table view everything is working except section 2 row 0. AND -- before anyone asks...I know I am not using the *imgWordView (in the code below) and that is why the icons are not showing but i do not know where to add it to the subview so i can place it at c...

iphone sdk - weird bug with TableView Cell

Hi guys I'm working in cellForRowAtIndexPath, and I'm trying to embed a textview into the cell. Now, the embedding part is all well and fine, but I am getting the strangest problem when I try and load the textview in all but the first row. Note: I want The TextView in all but the first row in my table. The problem is that when I implem...

How do I fill the background color of a UITableViewCell?

How do I fill the background color of a UITableViewCell? I tried this code but it didn't work. cell.backgroundColor = [UIColor redColor]; ...

iphone sdk - TableView Cell with custom TextView - Get New Data

Hi guys I have a tableview cell with a custom textview in it, I am now left wondering how do I possibly access the text in the textbox after text has been edited/added. I would normally know how this is done when I draw the textfield through IB, but my textviewcell is dynamically drawn. (i.e. I would like to capture the data that is u...

How to prevent UITableView from reserving space at the left of cell when editing is turned on ?

I'm set editing mode for UITableView to have a possibility of cell reordering. UITableViewCellEditingStyleNone is returned by editingStyleForRowAtIndexPath: method for every cell, but it reserve some area on the left of cell. Is it possible to prevent such an area reserving, because I'm not need an insert or delete icon on left? In short...

Why do I get a memory leak when adding a button as a subview?

I have an app that uses a tableview, along with a UIButton that I add as a subview to each custom cell, like this: UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier]; if (cell == nil) { cell = [[[UITableViewCell alloc] initWithFrame:CGRectZero reuseIdentifier:CellIdentifier] autorelease]; chec...

iphone tableview cells with custom textview - get textview reference

Hi guys I have a UITableView with 15 cells, each with a separate text box in it. I have implemented UITextViewDelegate and I am able to received changed textview data using textViewDidChange (etc). But I have one big problem still, how do I know WHICH textview sent this, (i.e. in which cell was the textview altered?) Its interesting to...

UITableViewCell background size

I'm trying to set the size of my background to be a little shorter than the default, creating some space between the cells. This has proven to be difficult. Setting the frame of the background view seems to do nothing: - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { NSString ...

UISwitch looks strange when added as accessoryView in UITableViewCell and the cell is selected !

Hi, I'm adding a UISwitch as accessoryView for my UITableViewCell, everything works fine excepts that when the user selects a row in the table; the UISwitch gets a very strange layout : Is that "Normal" ? I'm still running with SDK 3.0 (in case this is a bug in 3.0 but my searches didn't give me any hint regarding this). I've seen o...

iPhone SDK - UITextField subview of UITableCell gives drawing issues?

I'm adding some UITextFields, UITextViews and UIImageViews as subviews to a UITableCell. When I'm entering some text to the TextFields or TextViews and scroll the table up or down, I get some drawing issues. The text of every second field overlaps other fields like this: I'm creating the form elements like this: self.formFields =...

How to change rowHeight of a TableViewCell depending on Stringlength

I have a table with different entries, each with different length. The height of each row should fit, so it can show the whole string. I use the following code: //... cellForRowAtIndexPath if (row == 0) { cell = [tableView dequeueReusableCellWithIdentifier:@"affCell"]; //if (!cell) { cell = [[[UITableViewCell alloc] initW...

Simple Detail View Help?

Im having major problems with Detail views and was hoping someone could point me in the right direction. I would like to add a detail view to an app like apples advancetableviewcells. So once you click on a cell, it leads you to the detail view. Only catch is, it has to load the data from the cell into the detail view also. I've look...

Wipe a delete button out of table view cell

Hi, when pressing a row delete button on a table view, I do some validation, and if the user chooses to cancel the operation it all should rollback. Not only want to keep that row (what is happening), but also make disappear the delete button leaving only the "-" round button. How can I do that? once again, thank you. ...

UITableView - get list of UITableViewCells in an indexPath.section

Hello, Is there a way I can iterate over a list of UITableViewCells contained in an indexPath.section? Thanks ...

UITableView with a single custom Cell? (iPhone)

Hi I have run into a bit of a problem. Usually when dealing with UITableView I will build a special method, configureCell, that builds the cells as the tableView needs them. So cellForRowAtIndexPath queries the configureCell to get a new cell if none is found in the cache. In the part of cellForRowAtIndexPath that gets run every time a...

cell.detailTextLabel.text not working... why

Using the following code I am getting the text.label but not the detailTextLabel.text. The NSLog is displaying correctly. cell.textLabel.text = [eventLabels objectAtIndex:indexPath.row]; cell.detailTextLabel.text = [eventFields objectAtIndex:indexPath.row]]; NSLog(@"%@", [eventFields objectAtIndex:indexPath.row]); I also tried....

How do i get the effect of a UISwitch as the accessory for a UITableViewCell?

I have a working UITableView filled with some options for my app, and i want to add UISwitches to them just like the Settings app, how do i do this? Thanks :) ...

iPhone cellForRowAtIndexPath returns cached cell

Hi, When i add a label to a cell using: - (void)tableView:(UITableView *)tableView accessoryButtonTappedForRowWithIndexPath:(NSIndexPath *)indexPath{ UITableViewCell *cell = [tableView cellForRowAtIndexPath:indexPath]; [cell addSubView:someLabel]; } It adds the label to multple cells, because it adds the label to a cached cel...

CellForRowAtIndexPath Causing issues, when can I release a local inside there?

Hey all, I have a UITableView that displays various nsstrings from a custom object called a "Transaction." in CellForRowAtIndexPath it the allocates a new instance of a transaction and then copies the the values from a particular transaction that lives in the delegate array so I can access it from different views. It then uses the new ...

Customize TableviewCell depending on section

Hi folks, How do I customize the background image of a tableViewCell depending on the section, they are in? E.g. in section one, the cells are supposed to have a green .png image as a background image, whereas in section two, the cells are supposed to have a red .png image as background. Thank you for your help! gstar ...