title: How to remove subviews in Objective-C?
body: <p>I have added UIButton and UITextView as subviews to my view programmatically.</p>
  
  <pre><code>notesDescriptionView = [[UIView alloc]initWithFrame:CGRectMake(0,0,320,460)];
  notesDescriptionView.backgroundColor = [UIColor redColor];
  [self.view addSubview:notesDescriptionView];
  
  textView = [[UITextView alloc] initWithFrame:CGRectMake(0,0,320,420)]; 
  [self.view addSubview:textView]; 
  printf("\n description  button \n");
  
  button = [UIButton buttonWithType:UIButtonTypeRoundedRect];
  [button
    addTarget:self action:@selector(cancel:)
    forControlEvents:UIControlEventTouchDown];
  [button setTitle:@"OK" forState:UIControlStateNormal];
  button.frame = CGRectMake(80.0, 420.0, 160.0, 40.0);
  [self.view addSubview:button];
  </code></pre>
  
  <p>I need to remove all subviews when the button is clicked.</p>
  
  <p>I have tried:</p>
  
  <pre><code>[self.view removeFromSuperView]
  </code></pre>
  
  <p>but it's not working.</p>