title: iOS Objective-C wrap text of UITextField in UIAlertView and dynamically adjust height based on content
body: <p>I have a <code>UIAlertView</code> with the <code>alertViewStyle</code> of <code>UIAlertViewStylePlainTextInput</code>. I'm trying to find a way to make the <code>UITextField</code> of the <code>UIAlertView</code> adjust its height and wrap its text based on its content as the user types. </p>
  
  <p>To be quite honest, I haven't the slightest clue how to do this.</p>
  
  <p>Here is some of my code:</p>
  
  <pre><code>-(void)updateTicket:(id)sender
  {
      UIButton *sndr = (UIButton*)sender;
      int index = sndr.tag;
  
      UIAlertView *alert = [[UIAlertView alloc] init];
      [alert setTag:-7];
      [alert setDelegate:self];
      [alert setTitle:[NSString stringWithFormat:@"Update Ticket #%i", [ticketIDs[index] intValue]]];
      alert.alertViewStyle = UIAlertViewStylePlainTextInput;
      [alert textFieldAtIndex:0].placeholder = @"Note";
      [alert textFieldAtIndex:0].tag = index;
      [alert textFieldAtIndex:0].autocapitalizationType = UITextAutocapitalizationTypeSentences;
      [alert textFieldAtIndex:0].autocorrectionType = UITextAutocorrectionTypeYes;
      [alert textFieldAtIndex:0].autoresizingMask = UIViewAutoresizingFlexibleHeight;
      [alert addButtonWithTitle:@"Cancel"];
      [alert addButtonWithTitle:@"OK"];
      [alert setCancelButtonIndex:0];
      [alert show];
  }
  </code></pre>