In the figure, what you see in "red" is another view that slides up once you click the first + button. This "red" view does not have a separate view controller. On every "+" button click, I want this view to slide up with a different element embedded in it. For instance, on the first "+" button click , I would like this red view to slide up with a datepicker embedded in it. On second "+" button click, I would like this red view to slide up with a UIPicker View embedded in it. I have the elements: UIDatepicker and UIPicker prepared. I don't know when and where to embed them and what should be their frame size.
I am initializing the "red" view in the viewDidLoad method
viewDidLoad {
CGRect frame=CGRectMake(0, CGRectGetMaxY(self.view.bounds)-70, 320, 150);
popup=[[UIView alloc]init];
popup.backgroundColor=[UIColor redColor];
[popup setFrame:frame];
}
and I am sliding it up in
-(void) btnClick:(id)sender { frame=CGRectMake(0, 240, 320, 150);
[UIView beginAnimations:nil context:nil];
[popup setFrame:frame];
[UIView commitAnimations];
}