-1
DatePickerは、特定のセルがTableViewでクリックされたときにどのように表示されますか。ピッカーであなたのViewControllerでDatePickerはSwiftでdidSelectRowATIndexPathを呼び起こします
var chosenNumber = 0
override func tableView(tableView: UITableView, didSelectRowAtIndexPath indexPath: NSIndexPath) {
//set your chosenNumber here based on your the cell that was clicked
chosenNumber = 1
}
override func prepareForSegue(segue: UIStoryboardSegue, sender: AnyObject!) {
let controller = segue.destinationViewController as! ViewController
//the startRow variable in the ViewController with the picker is set to the same value as the chosenNumber
controller.startRow = chosenNumber
}
:また、私はあなたのTableViewControllerで使用
これまでに試したコードを投稿してください。 – random