title: An UIViewController inside other UIviewController and IBActions
body: <p>I'm designing an iPad app where little UIScrollViews have their own UIViewController . Those controllers have in their view a button that call an IBAction method. But it isnt working, in fact, it doesnt seem that they are being pressed in the simulator.</p>
  
  <p>Here is some code to give you an idea of what im am doing .</p>
  
  <pre><code>// In UIViewController A (say the parent or root that have several UIScrollViews)
  
      MiniViewController * mini = [[MiniViewController alloc]init];
      [scrollView1 addSubview:mini.view];
  
  //repeat the same process a couple of times with different uiscrollsviews and instances of miniviewcontrollers
  </code></pre>
  
  <p>Now The MiniController is very simple as you can guess, i only post the .h file</p>
  
  <pre><code>@interface MiniControlador : UIViewController {
       IBOutlet UIButton * button;
  }
  @property (nonatomic, retain) IBOutlet UIButton * button;
  - (IBAction)doSomething:(id)sender;
  @end
  </code></pre>
  
  <p>You can see that i used Interface builder to connect an UIButton "button" to a method called doSomething. But as i already said, it isnt working. </p>
  
  <p>One more thing. I also tried to add a button to the UIScrollView <em>with</em> the Mini Controller instance programmatically.And it worked! But I certainly believe that it's extremely hardcoded.</p>
  
  <p>What do you think? I'll appreciate any suggestion(s). </p>