Swift 4 prepare(for segue:) not being called












2














I have a split view controller and its not calling my prepare(for segue:) method when I click on an item in my table view. Here is my prepare(for segue:) method:



override func prepare(for segue: UIStoryboardSegue, sender: Any?) {
print("Here");
if segue.identifier == "showPOsDetail" {
if let indexPath = tableView.indexPathForSelectedRow {
let object = objects[indexPath.row] as! NSDate
let controller = (segue.destination as! UINavigationController).topViewController as! POsDetail
controller.detailItem = object
controller.navigationItem.leftBarButtonItem = splitViewController?.displayModeButtonItem
controller.navigationItem.leftItemsSupplementBackButton = true
}
}
}


And here is a screenshot of my storeyboard. I have no idea why this method is not being called.



enter image description here



Ive been trying to figure with out for days now and I am super duper frustrated that its not working.



Here is my full Master Controller:



import UIKit

class POsMaster: UITableViewController {

var POsDetailController: POsDetail? = nil
var objects = [Any]()


override func viewDidLoad() {
super.viewDidLoad()

// Do any additional setup after loading the view, typically from a nib.
navigationItem.leftBarButtonItem = editButtonItem

let addButton = UIBarButtonItem(barButtonSystemItem: .add, target: self, action: #selector(insertNewObject(_:)))
navigationItem.rightBarButtonItem = addButton
if let split = splitViewController {
let controllers = split.viewControllers
POsDetailController = (controllers[controllers.count-1] as! UINavigationController).topViewController as? POsDetail
}

}

override func viewWillAppear(_ animated: Bool) {
super.viewWillAppear(animated)
}

override func didReceiveMemoryWarning() {
super.didReceiveMemoryWarning()
// Dispose of any resources that can be recreated.
}

@objc
func insertNewObject(_ sender: Any) {
objects.insert(NSDate(), at: 0)
let indexPath = IndexPath(row: 0, section: 0)
tableView.insertRows(at: [indexPath], with: .automatic)
}

// MARK: - Segues

override func prepare(for segue: UIStoryboardSegue, sender: Any?) {
print("Here");
if segue.identifier == "showPOsDetail" {
if let indexPath = tableView.indexPathForSelectedRow {
let object = objects[indexPath.row] as! NSDate
let controller = (segue.destination as! UINavigationController).topViewController as! POsDetail
controller.detailItem = object
controller.navigationItem.leftBarButtonItem = splitViewController?.displayModeButtonItem
controller.navigationItem.leftItemsSupplementBackButton = true
}
}
}

// MARK: - Table View

override func numberOfSections(in tableView: UITableView) -> Int {
return 1
}

override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
return objects.count
}

override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
let cell = tableView.dequeueReusableCell(withIdentifier: "POCell", for: indexPath)

let object = objects[indexPath.row] as! NSDate
cell.textLabel!.text = object.description
return cell
}

override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool {
// Return false if you do not want the specified item to be editable.
return true
}

override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) {
if editingStyle == .delete {
objects.remove(at: indexPath.row)
tableView.deleteRows(at: [indexPath], with: .fade)
} else if editingStyle == .insert {
// Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view.
}
}


}









share|improve this question
























  • @user979311 have you checked with breakpoints ? Is call even going inside?
    – Tushar Sharma
    Oct 27 '17 at 19:24










  • Yes I have, its not going inside the method at all.
    – user979331
    Oct 27 '17 at 19:25










  • at what point its not going inside ?? Do you have any value here -: if let indexPath = tableView.indexPathForSelectedRow{}? Or is it nil?Or is it not even giving output for this ? print("Here");
    – Tushar Sharma
    Oct 27 '17 at 19:32












  • I am not even getting the output for print("Here");
    – user979331
    Oct 27 '17 at 19:36










  • Where in your code are you pushing the new UIViewController? The problem might be in the way you are doing it. Are you using the didSelectRowAtIndexPath:(NSIndexPath *)indexPath; method from UITableViewDelegate?
    – Stefan Stefanov
    Oct 27 '17 at 19:46
















2














I have a split view controller and its not calling my prepare(for segue:) method when I click on an item in my table view. Here is my prepare(for segue:) method:



override func prepare(for segue: UIStoryboardSegue, sender: Any?) {
print("Here");
if segue.identifier == "showPOsDetail" {
if let indexPath = tableView.indexPathForSelectedRow {
let object = objects[indexPath.row] as! NSDate
let controller = (segue.destination as! UINavigationController).topViewController as! POsDetail
controller.detailItem = object
controller.navigationItem.leftBarButtonItem = splitViewController?.displayModeButtonItem
controller.navigationItem.leftItemsSupplementBackButton = true
}
}
}


And here is a screenshot of my storeyboard. I have no idea why this method is not being called.



enter image description here



Ive been trying to figure with out for days now and I am super duper frustrated that its not working.



Here is my full Master Controller:



import UIKit

class POsMaster: UITableViewController {

var POsDetailController: POsDetail? = nil
var objects = [Any]()


override func viewDidLoad() {
super.viewDidLoad()

// Do any additional setup after loading the view, typically from a nib.
navigationItem.leftBarButtonItem = editButtonItem

let addButton = UIBarButtonItem(barButtonSystemItem: .add, target: self, action: #selector(insertNewObject(_:)))
navigationItem.rightBarButtonItem = addButton
if let split = splitViewController {
let controllers = split.viewControllers
POsDetailController = (controllers[controllers.count-1] as! UINavigationController).topViewController as? POsDetail
}

}

override func viewWillAppear(_ animated: Bool) {
super.viewWillAppear(animated)
}

override func didReceiveMemoryWarning() {
super.didReceiveMemoryWarning()
// Dispose of any resources that can be recreated.
}

@objc
func insertNewObject(_ sender: Any) {
objects.insert(NSDate(), at: 0)
let indexPath = IndexPath(row: 0, section: 0)
tableView.insertRows(at: [indexPath], with: .automatic)
}

// MARK: - Segues

override func prepare(for segue: UIStoryboardSegue, sender: Any?) {
print("Here");
if segue.identifier == "showPOsDetail" {
if let indexPath = tableView.indexPathForSelectedRow {
let object = objects[indexPath.row] as! NSDate
let controller = (segue.destination as! UINavigationController).topViewController as! POsDetail
controller.detailItem = object
controller.navigationItem.leftBarButtonItem = splitViewController?.displayModeButtonItem
controller.navigationItem.leftItemsSupplementBackButton = true
}
}
}

// MARK: - Table View

override func numberOfSections(in tableView: UITableView) -> Int {
return 1
}

override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
return objects.count
}

override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
let cell = tableView.dequeueReusableCell(withIdentifier: "POCell", for: indexPath)

let object = objects[indexPath.row] as! NSDate
cell.textLabel!.text = object.description
return cell
}

override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool {
// Return false if you do not want the specified item to be editable.
return true
}

override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) {
if editingStyle == .delete {
objects.remove(at: indexPath.row)
tableView.deleteRows(at: [indexPath], with: .fade)
} else if editingStyle == .insert {
// Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view.
}
}


}









share|improve this question
























  • @user979311 have you checked with breakpoints ? Is call even going inside?
    – Tushar Sharma
    Oct 27 '17 at 19:24










  • Yes I have, its not going inside the method at all.
    – user979331
    Oct 27 '17 at 19:25










  • at what point its not going inside ?? Do you have any value here -: if let indexPath = tableView.indexPathForSelectedRow{}? Or is it nil?Or is it not even giving output for this ? print("Here");
    – Tushar Sharma
    Oct 27 '17 at 19:32












  • I am not even getting the output for print("Here");
    – user979331
    Oct 27 '17 at 19:36










  • Where in your code are you pushing the new UIViewController? The problem might be in the way you are doing it. Are you using the didSelectRowAtIndexPath:(NSIndexPath *)indexPath; method from UITableViewDelegate?
    – Stefan Stefanov
    Oct 27 '17 at 19:46














2












2








2







I have a split view controller and its not calling my prepare(for segue:) method when I click on an item in my table view. Here is my prepare(for segue:) method:



override func prepare(for segue: UIStoryboardSegue, sender: Any?) {
print("Here");
if segue.identifier == "showPOsDetail" {
if let indexPath = tableView.indexPathForSelectedRow {
let object = objects[indexPath.row] as! NSDate
let controller = (segue.destination as! UINavigationController).topViewController as! POsDetail
controller.detailItem = object
controller.navigationItem.leftBarButtonItem = splitViewController?.displayModeButtonItem
controller.navigationItem.leftItemsSupplementBackButton = true
}
}
}


And here is a screenshot of my storeyboard. I have no idea why this method is not being called.



enter image description here



Ive been trying to figure with out for days now and I am super duper frustrated that its not working.



Here is my full Master Controller:



import UIKit

class POsMaster: UITableViewController {

var POsDetailController: POsDetail? = nil
var objects = [Any]()


override func viewDidLoad() {
super.viewDidLoad()

// Do any additional setup after loading the view, typically from a nib.
navigationItem.leftBarButtonItem = editButtonItem

let addButton = UIBarButtonItem(barButtonSystemItem: .add, target: self, action: #selector(insertNewObject(_:)))
navigationItem.rightBarButtonItem = addButton
if let split = splitViewController {
let controllers = split.viewControllers
POsDetailController = (controllers[controllers.count-1] as! UINavigationController).topViewController as? POsDetail
}

}

override func viewWillAppear(_ animated: Bool) {
super.viewWillAppear(animated)
}

override func didReceiveMemoryWarning() {
super.didReceiveMemoryWarning()
// Dispose of any resources that can be recreated.
}

@objc
func insertNewObject(_ sender: Any) {
objects.insert(NSDate(), at: 0)
let indexPath = IndexPath(row: 0, section: 0)
tableView.insertRows(at: [indexPath], with: .automatic)
}

// MARK: - Segues

override func prepare(for segue: UIStoryboardSegue, sender: Any?) {
print("Here");
if segue.identifier == "showPOsDetail" {
if let indexPath = tableView.indexPathForSelectedRow {
let object = objects[indexPath.row] as! NSDate
let controller = (segue.destination as! UINavigationController).topViewController as! POsDetail
controller.detailItem = object
controller.navigationItem.leftBarButtonItem = splitViewController?.displayModeButtonItem
controller.navigationItem.leftItemsSupplementBackButton = true
}
}
}

// MARK: - Table View

override func numberOfSections(in tableView: UITableView) -> Int {
return 1
}

override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
return objects.count
}

override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
let cell = tableView.dequeueReusableCell(withIdentifier: "POCell", for: indexPath)

let object = objects[indexPath.row] as! NSDate
cell.textLabel!.text = object.description
return cell
}

override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool {
// Return false if you do not want the specified item to be editable.
return true
}

override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) {
if editingStyle == .delete {
objects.remove(at: indexPath.row)
tableView.deleteRows(at: [indexPath], with: .fade)
} else if editingStyle == .insert {
// Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view.
}
}


}









share|improve this question















I have a split view controller and its not calling my prepare(for segue:) method when I click on an item in my table view. Here is my prepare(for segue:) method:



override func prepare(for segue: UIStoryboardSegue, sender: Any?) {
print("Here");
if segue.identifier == "showPOsDetail" {
if let indexPath = tableView.indexPathForSelectedRow {
let object = objects[indexPath.row] as! NSDate
let controller = (segue.destination as! UINavigationController).topViewController as! POsDetail
controller.detailItem = object
controller.navigationItem.leftBarButtonItem = splitViewController?.displayModeButtonItem
controller.navigationItem.leftItemsSupplementBackButton = true
}
}
}


And here is a screenshot of my storeyboard. I have no idea why this method is not being called.



enter image description here



Ive been trying to figure with out for days now and I am super duper frustrated that its not working.



Here is my full Master Controller:



import UIKit

class POsMaster: UITableViewController {

var POsDetailController: POsDetail? = nil
var objects = [Any]()


override func viewDidLoad() {
super.viewDidLoad()

// Do any additional setup after loading the view, typically from a nib.
navigationItem.leftBarButtonItem = editButtonItem

let addButton = UIBarButtonItem(barButtonSystemItem: .add, target: self, action: #selector(insertNewObject(_:)))
navigationItem.rightBarButtonItem = addButton
if let split = splitViewController {
let controllers = split.viewControllers
POsDetailController = (controllers[controllers.count-1] as! UINavigationController).topViewController as? POsDetail
}

}

override func viewWillAppear(_ animated: Bool) {
super.viewWillAppear(animated)
}

override func didReceiveMemoryWarning() {
super.didReceiveMemoryWarning()
// Dispose of any resources that can be recreated.
}

@objc
func insertNewObject(_ sender: Any) {
objects.insert(NSDate(), at: 0)
let indexPath = IndexPath(row: 0, section: 0)
tableView.insertRows(at: [indexPath], with: .automatic)
}

// MARK: - Segues

override func prepare(for segue: UIStoryboardSegue, sender: Any?) {
print("Here");
if segue.identifier == "showPOsDetail" {
if let indexPath = tableView.indexPathForSelectedRow {
let object = objects[indexPath.row] as! NSDate
let controller = (segue.destination as! UINavigationController).topViewController as! POsDetail
controller.detailItem = object
controller.navigationItem.leftBarButtonItem = splitViewController?.displayModeButtonItem
controller.navigationItem.leftItemsSupplementBackButton = true
}
}
}

// MARK: - Table View

override func numberOfSections(in tableView: UITableView) -> Int {
return 1
}

override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
return objects.count
}

override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
let cell = tableView.dequeueReusableCell(withIdentifier: "POCell", for: indexPath)

let object = objects[indexPath.row] as! NSDate
cell.textLabel!.text = object.description
return cell
}

override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool {
// Return false if you do not want the specified item to be editable.
return true
}

override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) {
if editingStyle == .delete {
objects.remove(at: indexPath.row)
tableView.deleteRows(at: [indexPath], with: .fade)
} else if editingStyle == .insert {
// Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view.
}
}


}






ios swift swift4






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Oct 27 '17 at 20:09

























asked Oct 27 '17 at 19:22









user979331

629114218




629114218












  • @user979311 have you checked with breakpoints ? Is call even going inside?
    – Tushar Sharma
    Oct 27 '17 at 19:24










  • Yes I have, its not going inside the method at all.
    – user979331
    Oct 27 '17 at 19:25










  • at what point its not going inside ?? Do you have any value here -: if let indexPath = tableView.indexPathForSelectedRow{}? Or is it nil?Or is it not even giving output for this ? print("Here");
    – Tushar Sharma
    Oct 27 '17 at 19:32












  • I am not even getting the output for print("Here");
    – user979331
    Oct 27 '17 at 19:36










  • Where in your code are you pushing the new UIViewController? The problem might be in the way you are doing it. Are you using the didSelectRowAtIndexPath:(NSIndexPath *)indexPath; method from UITableViewDelegate?
    – Stefan Stefanov
    Oct 27 '17 at 19:46


















  • @user979311 have you checked with breakpoints ? Is call even going inside?
    – Tushar Sharma
    Oct 27 '17 at 19:24










  • Yes I have, its not going inside the method at all.
    – user979331
    Oct 27 '17 at 19:25










  • at what point its not going inside ?? Do you have any value here -: if let indexPath = tableView.indexPathForSelectedRow{}? Or is it nil?Or is it not even giving output for this ? print("Here");
    – Tushar Sharma
    Oct 27 '17 at 19:32












  • I am not even getting the output for print("Here");
    – user979331
    Oct 27 '17 at 19:36










  • Where in your code are you pushing the new UIViewController? The problem might be in the way you are doing it. Are you using the didSelectRowAtIndexPath:(NSIndexPath *)indexPath; method from UITableViewDelegate?
    – Stefan Stefanov
    Oct 27 '17 at 19:46
















@user979311 have you checked with breakpoints ? Is call even going inside?
– Tushar Sharma
Oct 27 '17 at 19:24




@user979311 have you checked with breakpoints ? Is call even going inside?
– Tushar Sharma
Oct 27 '17 at 19:24












Yes I have, its not going inside the method at all.
– user979331
Oct 27 '17 at 19:25




Yes I have, its not going inside the method at all.
– user979331
Oct 27 '17 at 19:25












at what point its not going inside ?? Do you have any value here -: if let indexPath = tableView.indexPathForSelectedRow{}? Or is it nil?Or is it not even giving output for this ? print("Here");
– Tushar Sharma
Oct 27 '17 at 19:32






at what point its not going inside ?? Do you have any value here -: if let indexPath = tableView.indexPathForSelectedRow{}? Or is it nil?Or is it not even giving output for this ? print("Here");
– Tushar Sharma
Oct 27 '17 at 19:32














I am not even getting the output for print("Here");
– user979331
Oct 27 '17 at 19:36




I am not even getting the output for print("Here");
– user979331
Oct 27 '17 at 19:36












Where in your code are you pushing the new UIViewController? The problem might be in the way you are doing it. Are you using the didSelectRowAtIndexPath:(NSIndexPath *)indexPath; method from UITableViewDelegate?
– Stefan Stefanov
Oct 27 '17 at 19:46




Where in your code are you pushing the new UIViewController? The problem might be in the way you are doing it. Are you using the didSelectRowAtIndexPath:(NSIndexPath *)indexPath; method from UITableViewDelegate?
– Stefan Stefanov
Oct 27 '17 at 19:46












2 Answers
2






active

oldest

votes


















0














When you connect your segue in storyboard a pop up opens and you have to check if you have set your segue from the Selection group, instead of the Accessory group, the Selection group connection will call your prepareForSegue: method.






share|improve this answer























  • Great Answer Bud!
    – user979331
    Oct 27 '17 at 23:10










  • hey man, sorry for asking, I did my segue from my storyboard but i didn't get your answer, and I still have this issue, can you please give me more information?
    – Arash Afshar
    Nov 12 at 14:39






  • 1




    Hi @ArashAfshar you are right I will update my answer to make it clearer, thank you for pointing it out. Anyway you can find an explanation in the question comments ;)
    – Francesco Deliro
    Nov 12 at 17:30



















0














You need to make sure that the isUserEnteractionEnabled is set to true.



Seems like that could be the only reason.






share|improve this answer





















  • @user979331 do you see the cell being selected(it should turn darker)?
    – Xcoder
    Oct 27 '17 at 22:20











Your Answer






StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");

StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f46982090%2fswift-4-preparefor-segue-not-being-called%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























2 Answers
2






active

oldest

votes








2 Answers
2






active

oldest

votes









active

oldest

votes






active

oldest

votes









0














When you connect your segue in storyboard a pop up opens and you have to check if you have set your segue from the Selection group, instead of the Accessory group, the Selection group connection will call your prepareForSegue: method.






share|improve this answer























  • Great Answer Bud!
    – user979331
    Oct 27 '17 at 23:10










  • hey man, sorry for asking, I did my segue from my storyboard but i didn't get your answer, and I still have this issue, can you please give me more information?
    – Arash Afshar
    Nov 12 at 14:39






  • 1




    Hi @ArashAfshar you are right I will update my answer to make it clearer, thank you for pointing it out. Anyway you can find an explanation in the question comments ;)
    – Francesco Deliro
    Nov 12 at 17:30
















0














When you connect your segue in storyboard a pop up opens and you have to check if you have set your segue from the Selection group, instead of the Accessory group, the Selection group connection will call your prepareForSegue: method.






share|improve this answer























  • Great Answer Bud!
    – user979331
    Oct 27 '17 at 23:10










  • hey man, sorry for asking, I did my segue from my storyboard but i didn't get your answer, and I still have this issue, can you please give me more information?
    – Arash Afshar
    Nov 12 at 14:39






  • 1




    Hi @ArashAfshar you are right I will update my answer to make it clearer, thank you for pointing it out. Anyway you can find an explanation in the question comments ;)
    – Francesco Deliro
    Nov 12 at 17:30














0












0








0






When you connect your segue in storyboard a pop up opens and you have to check if you have set your segue from the Selection group, instead of the Accessory group, the Selection group connection will call your prepareForSegue: method.






share|improve this answer














When you connect your segue in storyboard a pop up opens and you have to check if you have set your segue from the Selection group, instead of the Accessory group, the Selection group connection will call your prepareForSegue: method.







share|improve this answer














share|improve this answer



share|improve this answer








edited Nov 12 at 17:35

























answered Oct 27 '17 at 23:07









Francesco Deliro

2,4372817




2,4372817












  • Great Answer Bud!
    – user979331
    Oct 27 '17 at 23:10










  • hey man, sorry for asking, I did my segue from my storyboard but i didn't get your answer, and I still have this issue, can you please give me more information?
    – Arash Afshar
    Nov 12 at 14:39






  • 1




    Hi @ArashAfshar you are right I will update my answer to make it clearer, thank you for pointing it out. Anyway you can find an explanation in the question comments ;)
    – Francesco Deliro
    Nov 12 at 17:30


















  • Great Answer Bud!
    – user979331
    Oct 27 '17 at 23:10










  • hey man, sorry for asking, I did my segue from my storyboard but i didn't get your answer, and I still have this issue, can you please give me more information?
    – Arash Afshar
    Nov 12 at 14:39






  • 1




    Hi @ArashAfshar you are right I will update my answer to make it clearer, thank you for pointing it out. Anyway you can find an explanation in the question comments ;)
    – Francesco Deliro
    Nov 12 at 17:30
















Great Answer Bud!
– user979331
Oct 27 '17 at 23:10




Great Answer Bud!
– user979331
Oct 27 '17 at 23:10












hey man, sorry for asking, I did my segue from my storyboard but i didn't get your answer, and I still have this issue, can you please give me more information?
– Arash Afshar
Nov 12 at 14:39




hey man, sorry for asking, I did my segue from my storyboard but i didn't get your answer, and I still have this issue, can you please give me more information?
– Arash Afshar
Nov 12 at 14:39




1




1




Hi @ArashAfshar you are right I will update my answer to make it clearer, thank you for pointing it out. Anyway you can find an explanation in the question comments ;)
– Francesco Deliro
Nov 12 at 17:30




Hi @ArashAfshar you are right I will update my answer to make it clearer, thank you for pointing it out. Anyway you can find an explanation in the question comments ;)
– Francesco Deliro
Nov 12 at 17:30













0














You need to make sure that the isUserEnteractionEnabled is set to true.



Seems like that could be the only reason.






share|improve this answer





















  • @user979331 do you see the cell being selected(it should turn darker)?
    – Xcoder
    Oct 27 '17 at 22:20
















0














You need to make sure that the isUserEnteractionEnabled is set to true.



Seems like that could be the only reason.






share|improve this answer





















  • @user979331 do you see the cell being selected(it should turn darker)?
    – Xcoder
    Oct 27 '17 at 22:20














0












0








0






You need to make sure that the isUserEnteractionEnabled is set to true.



Seems like that could be the only reason.






share|improve this answer












You need to make sure that the isUserEnteractionEnabled is set to true.



Seems like that could be the only reason.







share|improve this answer












share|improve this answer



share|improve this answer










answered Oct 27 '17 at 22:17









Xcoder

95421023




95421023












  • @user979331 do you see the cell being selected(it should turn darker)?
    – Xcoder
    Oct 27 '17 at 22:20


















  • @user979331 do you see the cell being selected(it should turn darker)?
    – Xcoder
    Oct 27 '17 at 22:20
















@user979331 do you see the cell being selected(it should turn darker)?
– Xcoder
Oct 27 '17 at 22:20




@user979331 do you see the cell being selected(it should turn darker)?
– Xcoder
Oct 27 '17 at 22:20


















draft saved

draft discarded




















































Thanks for contributing an answer to Stack Overflow!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.





Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


Please pay close attention to the following guidance:


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f46982090%2fswift-4-preparefor-segue-not-being-called%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Xamarin.iOS Cant Deploy on Iphone

Glorious Revolution

Dulmage-Mendelsohn matrix decomposition in Python