Search Results

Search found 1385 results on 56 pages for 'uitableview'.

Page 11/56 | < Previous Page | 7 8 9 10 11 12 13 14 15 16 17 18  | Next Page >

  • UITableView Search

    - by lkl
    Hi all, I'm using the following code for my search on my table: - (void)filterContentForSearchText:(NSString*)searchText scope:(NSString*)scope { [searchParent removeAllObjects]; for(NSString *a in parent) { NSComparisonResult result = [a compare:searchText options:(NSCaseInsensitiveSearch) range:NSMakeRange(0, [searchText length])]; if(result == NSOrderedSame){ [searchParent addObject:a]; } } } It's working fine, however, only for one character. I get the following in the console: *** Terminating app due to uncaught exception 'NSRangeException', reason: '*** -[NSCFArray objectAtIndex:]: index (0) beyond bounds (0)' Any help is appreciated greatly! Thanks

    Read the article

  • UIButton to intercept UITableView's didSelectRowAtIndexPath method

    - by Michael
    I've got a UIButton on a table cell that is meant to pop up a UIActionSheet but the problem is the didSelectRowAtIndexPath captures that touch and its action takes precedence. Any clever way to override that action when the user touches the button and still have the default action when the user presses elsewhere in the cell? Too bad there is no MoveToFront property.

    Read the article

  • Creating a fixed formatted cell in UITableview

    - by Wes
    Hi, I want to have a tableview create rows that look like this: value1 item1 container1 value10 item10 container10 value100 item100 container100 value2 item2 container2 What I am trying to show is that the first word (value) will have a set length of 12 and then the second word (item) will have a set length of 10 and then the last word (container) is just tagged on at the end. I am pulling these from a SQLite database and don't want to use multiple lines, but read in a strictly formatted structure like this.

    Read the article

  • UITableView's cellForRowAtIndexPath is not getting called after low memory warning

    - by Jinesh
    I am new to COCOA and Objective C. I am working on an application which have two controllers with one table view in each, clicking an item form this table will lead to another controller to be pushed to the stack. All was working fine till i started handling low memory warning in app delegate. What i am doing in app delegate's applicationDidReceiveMemoryWarning is, deleting all of my model and popping out all controllers to its root view using popToRootViewControllerAnimated. Now my problem starts, once low mem warning is received table's cellForRowAtIndexPath is not getting called. All other methods of UITableViewDataSource is properly called. What i get on screen is a blank white screen. I am testing my app in iPhone OS 3.0 and development is done in Xcode V 3.1.3. Hope you guys can help me to nail this. Thanks in advance, Jinesh.

    Read the article

  • UITableView - Select nearest row after row deletion.

    - by sunnycmf
    like build in apple notes app, after you swipe to delete the selected row, it will select the nearest available row automatically. The logic should be: if row count 0 then if deleted_row == last row then select deleted_row_index-1 row else select deleted_row_index+1 row end end i have try to implement the above logic in the commitEditingStyle event, but the selection fail. the selectRowAtIndexPath logic just don't work in this event, if i apply it in a button, it works. any idea?

    Read the article

  • UITableView Header Selection

    - by Reonarudo
    Hello, Can anyone explain me how can I detect a selection in a table view Header view like in tableView:didSelectRowAtIndexPath: ? It would be very useful for me. I've defined the header as UITableCellView so I could attach a UISwitch as an accessory view, and it worked great but now I can't detect the changes made in the switch. Any suggestions?

    Read the article

  • Add UIView behind UITableView in UITableViewController code

    - by Drew C
    I would like to use a fixed image as the background in a simple grouped table view in my iPhone program. Unfortunately, no matter what I do, the background is always solid white. I have followed several supposed solutions on this site and others to no avail. Here is the relavant code in the viewDidLoad method of the table view controller class (note, this code uses a solid blue color rather than an image for simplicity's sake): self.tableView.opaque = NO; self.tableView.backgroundColor = [UIColor clearColor]; UIView *backgroundView = [[UIView alloc] initWithFrame:CGRectMake(0, 0, 320, 480)]; backgroundView.backgroundColor = [UIColor blueColor]; [self.tableView.window addSubview:backgroundView]; [backgroundView release]; I suspect that I am not positioning the backgroundView view in the right place. I have tried sendToBack:, bringToFront:, and others but I always just get a white background. Is it possible to do this from within the UITableViewController? Must I use Interface Builder?

    Read the article

  • Weird Scrolling Issue Using UITableView

    - by Scott Elder
    I am a working UINavigationController pushing two different UITableViews on and off the stack. All of my functionality is working correctly except scrolling. When either table is scrolled above the top row, or below the bottom row, it stays there exposing the margin above/below the table. I am looking for the table to "bounce" back so that only the table is visible and not the white space area beyond - just like any other iPhone app. One of my UITableViews is being loaded by NIB and the other is being created programatically - both of which have the exact same result. I have tried all the bounce and scrolling settings in the Nib, but nothing seems to work. Can someone tell me what I am doing wrong? Please let me know if I can be more specific in detailing my problem. Thanks, -Scott

    Read the article

  • UITableView don't react on a tap

    - by aspcartman
    I have a fully working grouped tableview. But when i just tap on a cell - nothing happens. willSelectRowAtIndexPath is not even being called. All outlets are set correctly, userInteractions are enabled, tableView is the only view on a page. Googling for hours made no success. Everyone has a selection feature from the begining and someone even tries to ged rid of it. Help, please. Cell creation: UITableViewCell *cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:@"FriendCell"];

    Read the article

  • UITableView Cell IndexPath

    - by Reonarudo
    Hello, Can anyone tell me how can I get a cell IndexPath? I was saving the IndexPath in the tableView: cellForRowAtIndexPath: method but this only loads when the cell is viewed and I need to know its index path on the viewDidLoad method. this resulted in a null value because as I said it only loads its value after the cell was viewed once. Thank you. EDIT The intention is being able to jump to a specific cell that has its specific number but its not linear with the sections and rows count.

    Read the article

  • UITableView subview to uitableviewcell

    - by Dave
    i am trying to add a button to the tableview and no matter what frame i specify the button is not visible. This is a custom UITableViewCell and I am adding the button in the code rather than in the xib file is so that I can click on the button and perform an action which is not didSelectRowAtIndexPath: I have the following code in cellForRowAtIndexPath: What am I missing? UIButton *button = [UIButton buttonWithType:UIButtonTypeDetailDisclosure]; button.titleLabel.text = @"detail"; button.frame = bframe; button.userInteractionEnabled = YES; [button addTarget:self action:@selector(buttonClick:) forControlEvents:UIControlEventTouchUpInside]; [cell.contentView addSubview:button]; return cell;

    Read the article

  • Is this an UITableView -beginUpdates documentation error?

    - by mystify
    I can't wrap my head around what they tried to say here in the docs for -beginUpdate: Call this method if you want subsequent insertions, deletion, and selection operations (for example, cellForRowAtIndexPath: and indexPathsForVisibleRows) to be animated simultaneously. Let's see... cellForRowAtIndexPath: and indexPathsForVisibleRows are both GETTER methods. They do not update anything and do not change anything. So why should I call -beginUpdates before calling these? And what's animated regarding these? Well, nothing, huh? Just want to make sure this is really an error in the docs and I didn't miss something.

    Read the article

  • iPhone: Setup static content of UITableView

    - by Martin
    This guide from apple https://developer.apple.com/iphone/prerelease/library/documentation/UserExperience/Conceptual/TableView_iPhone/TableViewCells/TableViewCells.html (you need login) explains how to use "The Technique for Static Row Content" to use Interface Builder to setup the cells in a tableview. I have some cells with different heights in my tableview. Without using the heightForRowAtIndexPath method everything get messed up. Do I still need to use this method or can I in some way setup the height of the cells inside the IB as I created them there? Also when using the "The Technique for Static Row Content" from the guide you still need to use the cellForRowAtIndexPath to setup the cells even if they are created in IB. I would like to setup the full layout of the tableview with all cells in IB (drag the cells right into the tableview), is that possible in some way? Thanks!

    Read the article

  • UITableView UITableViewCell dynamic UILabel Height storyboard

    - by Mikel Nelson
    This isn'an a question, just a results log on an issue I had with XCode 4.5 storyboards and dynamic height UITableCell with a UILabel. The issue was; the initial display of a cell would only show part of the resized UILabel contents, and that the visual UILabel was not resized. It would only display correctly after scrolling off the top of the Table and back down. I did the calculations in hieghtForRowAtIndexPath and sizeToFit the UILabel in rowAtIndexPath. The sizes where coming up ok in debug, but the device was not updating the display with the correct size and UILable.text value. I had created the dynamic UITableCell in a storyboard. However, I had set the width and height to a nominal value (290x44). It turns out, this was causing my issues. I set the width and height to zero (0) in the story board, and everything started working correctly. (i.e. the UILabels displayed at the correct size with full content). I was unable to find anything online on this issue, except for some references to creating the custom table cell with a frame of zero. Turns out, that was really the answer (for me).

    Read the article

  • UITableView cell appearance update not working - iPhone

    - by Jack Nutkins
    I have this piece of code which I'm using to set the alpha and accessibility of one of my tables cells dependent on a value stored in user defaults: - (void) viewDidAppear:(BOOL)animated{ [self reloadTableData]; } - (void) reloadTableData { if ([[userDefaults objectForKey:@"canDeleteReceipts"] isEqualToString:@"0"]) { NSIndexPath *path = [NSIndexPath indexPathForRow:0 inSection:8]; UITableViewCell *cell = [self.tableView cellForRowAtIndexPath:path]; cell.contentView.alpha = 0.2; cell.userInteractionEnabled = NO; } else { NSIndexPath *path = [NSIndexPath indexPathForRow:0 inSection:8]; UITableViewCell *cell = [self.tableView cellForRowAtIndexPath:path]; cell.contentView.alpha = 1; cell.userInteractionEnabled = YES; } if ([[userDefaults objectForKey:@"canDeleteMileages"] isEqualToString:@"0"]) { NSIndexPath *path = [NSIndexPath indexPathForRow:1 inSection:8]; UITableViewCell *cell = [self.tableView cellForRowAtIndexPath:path]; cell.contentView.alpha = 0.2; cell.userInteractionEnabled = NO; } else { NSIndexPath *path = [NSIndexPath indexPathForRow:1 inSection:8]; UITableViewCell *cell = [self.tableView cellForRowAtIndexPath:path]; cell.contentView.alpha = 1; cell.userInteractionEnabled = YES; } if ([[userDefaults objectForKey:@"canDeleteAll"] isEqualToString:@"0"]) { NSIndexPath *path = [NSIndexPath indexPathForRow:2 inSection:8]; UITableViewCell *cell = [self.tableView cellForRowAtIndexPath:path]; cell.contentView.alpha = 0.2; cell.userInteractionEnabled = NO; NSLog(@"In Here"); } else { NSIndexPath *path = [NSIndexPath indexPathForRow:2 inSection:8]; UITableViewCell *cell = [self.tableView cellForRowAtIndexPath:path]; cell.contentView.alpha = 1; cell.userInteractionEnabled = YES; } } The value stored in userDefaults is '0' so the cell in section 8 row 2 should be greyed out and disabled, however this doesn't happen and the cell is still selectable with an alpha of 1... The log statement 'In Here' is called so it seems to be executing the right code, but that code doesn't seem to be doing anything. Can anyone explain what I've done wrong? Thanks, Jack

    Read the article

  • UITableView - Color a selectede cell in table (remain colored)

    - by Liron Loop
    Hi In my app i'm using a UITableViewController ("grouped style") which in one of its section I want the user to be able to see what he had selected by making this cell colored and other "uncolored". Doing it by updating all cells' background color and reloading table data, each time user touches a cell (in didSelectRowAtIndexPath:) Problem is that there is some processing made in the didSelectRowAtIndexPath: so the color doesn't get changed right a way, rather in a bit delay after touch was made. (I gusse the processing is the resone for the tiny delay) Is there a better way of doing it? Any help will be appreciated Liron P.S. I'm new to all of this...

    Read the article

< Previous Page | 7 8 9 10 11 12 13 14 15 16 17 18  | Next Page >