title: How to display DatePicker in popupwindow in iPhone?
body: <p>I m newbie to objective-C </p>
  
  <p>I want to display the <code>UIDatePicker</code> in a popup window after the button click ..</p>
  
  <p>I have a button and when I click the button my popup should appear with DatePicker and later after chosing the date the popup should close and set the selected date in a textbox.</p>
  
  <p>How can I do this ?</p>
  
  <p>To create a datepicker I wrote this code ..</p>
  
  <pre><code>UIDatePicker *datePicker=[[[UIDatePicker alloc] init] autorelease];
  datePicker.datePickerMode=UIDatePickerModeDate;
  [self.view addSubview:datePicker];
  </code></pre>
  
  <p>But I do not know how to display it in a popup window on a button click ..?</p>