我有一個PatientTableViewController在iPad的主側有一個用於添加新患者的按鈕。它通過popover segue轉換到此NewPatientViewController。如何關閉iOS 5中的彈出窗口?
在NewPatientViewController我有一個完成按鈕各位代表回到PatientTableViewController:
- (void)newPatientViewController:(NewPatientViewController *)sender withZipCode:(NSNumber *)zipCode andFirstName:(NSString *)firstName andLastName:(NSString *)lastName
{
[self dismissViewControllerAnimated:YES completion:NULL];
[self dismissModalViewControllerAnimated:YES];
[sender dismissModalViewControllerAnimated:YES];
[sender dismissViewControllerAnimated:YES completion:NULL];
}
的方法都沒有我上面的工作嘗試。但是,如果我使用Modal segue,一切正常。笏?
謝謝你。我嘗試過,但不知道在哪個屬性上調用它。我終於偶然發現了[這篇文章](http://stackoverflow.com/questions/8225589/ios-create-an-popover-view-using-storyboard),它幫助我弄明白了。 – Flaviu 2012-02-13 01:07:59
我還沒有使用故事板,所以我只是在黑暗中拍攝。 – colbadhombre 2012-02-13 16:03:01