uitableview - IOS prepareForSegue using custom tableview cell -


I have created a .xib with my custom cell that I am using on my table view controller in my storyboard .

In the storyboard, I added the current tableview with a pushview with another tableview. (When a user clicks on a single cell, then it has a new view).

The problem is, I do not know how to link the "How to link with my custom cell"?

I am loading my custom cell like this:

  Fixed NSString * simpleTableIdentifier = @ "cellCustom"; CellCustomView * cell = (cellCustomView *) [tableview dequeueReusableCellWithIdentifier: simpleTableIdentifier]; If (cell == blue) {NSArray * nib = [[NSBundle mainBundle] loadNibNamed: @ "cellCustom" owner: self choice: zero]; Cell = [nib object at index: 0]; }  

And when I try to apply the method:

  - (void) Prepare ForSegue: (UIStoryboardSegue *) to Sender: ( ID) sender {NSLog (@ "test"); }  

I have nothing, because in my opinion, I have not found anything from my custom cell and my storyboard segment, but I do not understand how it works : /

thx,

Did you try it?

  - (zero) table view: (UITableView *) tableview was SelectionRowAtIndexPath: (NSIndexPath *) indexPath {[Self display SegueWithIdentifier: @ "MySegue" Sender: Self]; }  

This method is in the category that contains the table view. Make sure that the representative of the tableview is equal to itself in that class. If you are using a storyboard, then control this scene-control whatever you can see. Click that Segue, and change your identifier to "MySeway" or whatever you want in your code in the same form.


Comments

Popular posts from this blog

java - org.apache.http.ProtocolException: Target host is not specified -

java - Gradle dependencies: compile project by relative path -

ruby on rails - Object doesn't support #inspect when used with .include -