title: Trying to bold titleLabel of UIButton in response to delegate method being called in iOS
body: <p>I am working on an application where I am calling the UITextFieldDelegate method:</p>
  
  <pre><code>- (BOOL)textField:(UITextField *)textField shouldChangeCharactersInRange:(NSRange)range replacementString:(NSString *)string { }
  </code></pre>
  
  <p>I am successfully calling it, and within the method, I enable a particular button.  This is also working fine.  However, the problem I am facing is that I am unable to make the title on the button bold when the button is enabled.  I set the font in Interface Builder, and I'm trying to bold the title programamtically. Here is the relevant code that shows what I am doing:</p>
  
  <pre><code>        if ([keys count] == [_tireName count]) {
  
              [_doneButton setEnabled:YES];//this line works
              [[_doneButton titleLabel] setFont:[UIFont boldSystemFontOfSize:28]];//this line does nothing
  
  
          } else if ([keys count] &lt; [_tireName count]){
  
              [_doneButton setEnabled:NO];//this line works
              [[_doneButton titleLabel] setFont:[UIFont systemFontOfSize:28]];//this line does nothing
  
          }
  </code></pre>
  
  <p>Ignore the "if" clause itself.  I want the text on the button to be bold when the button is enabled, and I want the text on the button to be "normal", when it is disabled.  What am I doing wrong?</p>