title: UIPickerView didSelectRow issue iPhone
body: <p>I have three labels, which I want to fill with selected row from pickerview. Like if 1st label is already filled then the second should be filled with the selected row value and if 1st and second both are already filled then the third should be filled. </p>
  
  <p>I am trying this code but it is assigning value only to the first label.</p>
  
  <pre><code>-(void)pickerView:(UIPickerView *)pickerView didSelectRow:(NSInteger)row
        inComponent:(NSInteger)component
  {
  
      NSString *selectedReward = [self.rewards objectAtIndex:row];
  
  
  
      if ([reward1.text isEqualToString:selectedReward]) {
  
          if ([reward2.text isEqualToString:selectedReward]) {
  
              reward3.text = selectedReward;
          }
  
          reward2.text = selectedReward;
      }
      else  {
  
          reward1.text = selectedReward;
      }
  
  }
  </code></pre>