Search Results

Search found 3 results on 1 pages for 'user333624'.

Page 1/1 | 1 

  • How to make an scrollable UITextField Inside UItableViewCell?

    - by user333624
    Hello everyone. I created a bunch of editable UITableViewCell by embedding an UITextField inside, but I have seen some apps that allows you to scroll the UItableview by scrolling inside an inactive editable cell. How can I do that? And how can I also dismiss the keyboard when tapping somewhere else? I know about the method: - (void)touchesEnded:(NSSet *)touches withEvent:(UIEvent *)event { UITouch *touch = [[event allTouches] anyObject]; if (touch.tapCount == 1) { [self resignFirstResponder]; } else { }} I put it inside my custom table view controller but the method doesn't seem to be called upon a tap, and I don't know if even if it gets called will dismiss the keyboard. Any help will be appreciated.

    Read the article

  • How to highlight text automatically inside an UIAlertView text field

    - by user333624
    Hello everyone I have an UIAlertView with a textfield that shows a default value and two buttons, one to cancel and the other one to confirm. What I am trying to do is that when the alert view is popped up the default value is highlighted so the user can override the whole value faster than manually erasing it. - (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath { UIAlertView *alert = [[UIAlertView alloc]initWithTitle:@"Title" message:@"" delegate:self cancelButtonTitle:@"Cancel" otherButtonTitles:@"Continue",nil]; [alerta addTextFieldWithValue:@"87893" label:@"value"]; UITextField *textField = [alert textField]; campoTexto.highlighted = YES; campoTexto.keyboardType = UIKeyboardTypeNumbersAndPunctuation; [alertt show]; [alert release]; } for some reason there is a highlighted attribute for the textfield but it doesn't seem to work and there is no trail of that attribute in the Class documentation.

    Read the article

  • Adding Insert Row in tableView

    - by user333624
    Hello everyone, I have a tableView that loads its data directly from a Core Data table with a NSFetchedResultsController. I'm not using an intermediate NSMutableArray to store the objects from the fetch results; I basically implemented inside my UITableViewController the protocol method numberOfRowsInSection and it returns the numberOfObjects inside a NSFetchedResultsSectionInfo. id <NSFetchedResultsSectionInfo> sectionInfo = [[fetchedResultsController sections] objectAtIndex:section]; and then I configure the cell content by implementing configureCell:atIndexPath and retrieving object info from the fetchedResultController but right now I have a generic configuration for any object (to avoid complications) cell.textLabel.text = @"categoria"; I also have a NavigationBar with a custom edit button at the right that loads my own selector called customSetEditing. What I'm trying to accomplish is to load an "Insert Cell" at the beginning of the tableView so when I tap it, it creates a new record. This last part is easy to implement the problem is that I dont's seem to be able to load the insert row or any row when I tap on the navigation bar edit button. this is the code for my customSetEditing: - (void) customSetEditing { [super setEditing:YES animated:YES]; [self.tableView setEditing:YES animated:YES]; [[self tableView] beginUpdates]; //[[self tableView] beginUpdates]; UIBarButtonItem *customDoneButtonItem = [[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemDone target:self action:@selector(customDone)]; [self.navigationItem.rightBarButtonItem release]; self.navigationItem.rightBarButtonItem = customDoneButtonItem; //[categoriasArray insertObject:[NSNull null] atIndex:0]; NSMutableArray *indexPaths = [[NSMutableArray alloc] initWithObjects:[NSIndexPath indexPathForRow:0 inSection:0],nil ]; [self.tableView insertRowsAtIndexPaths:indexPaths withRowAnimation:UITableViewRowAnimationTop]; //[indexPaths release]; [self.tableView reloadData];} Before adding the:[self.tableView reloadData]; I was getting an out of bounds error plus a program crash and although the program is not crashing it is not loading anything. I have seen many examples of similar situations in stackoverflow (by the way is an excellent forum with very helpful and nice people) none of the examples seems to work for me. Any ideas?

    Read the article

1