Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8465205
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T14:58:30+00:00 2026-06-10T14:58:30+00:00

In my App I have a ParentViewController that have several elements in it. One

  • 0

In my App I have a ParentViewController that have several elements in it. One of the elements is a UITableView.

I designed the table’s cells using a Dynamic Prototype Cell that I had designed within the Storyboard.

Meaning, that I have in the Storyboard a UIViewController; inside it I have a UITableView; and inside the UITableView I have a Prototype Cell.

Now, I added a UIButton inside the the Prototype Cell, created another UIViewController (let’s call it ChildViewController) and connected the UIButton and the ChildViewController within the Storyboard with a Segue.

How should I write the code that activates the Segue when the user clicks the UIButton?

I managed to create the table itself and have data inside the Dynamic Cells (they have some UILabels aside to the UIButton), but I cannot figure out how to connect the UIButton to the code properly.

I don’t want to use the UITableView default “select” features, since I wish to have several buttons inside the Dynamic Cells – each one will derive a different segue to a different ChildViewController.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T14:58:32+00:00Added an answer on June 10, 2026 at 2:58 pm

    Here’s how I solved the same problem. Hope it will help.

    To do this, you can pass the pointer to your UITableViewController to your custom cell’s initialization method, and store it there:

        - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
        {
                // ...
                CDTrackCell *cell = [tableView dequeueReusableCellWithIdentifier:strCellTableIdentifier];
                CDTrack *currTrack = [self.fetchedResultsController objectAtIndexPath:indexPath];
    
                [cell configureView:currTrack inTableViewController:self];
    
                return cell;
       }
    

    Save the pointer in custom UITableViewCell class:

    - (void) configureView:(CDTrack*)track
     inTableViewController:(CDTracksViewController*)_tvc
    {
        self.tvc = _tvc;
        // ...
    }
    

    Then, you can perform a segue when the button is tapped:

    - (IBAction)buttonAddToTracklistTapped:(UIButton *)sender {
        [self.tvc performSegueWithIdentifier:@"showAddToTracklist" sender:self];
    }
    

    Any better ideas?

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a table View that when a cell is added, it won't work
My app have a background image that fills the screen. I'd like to display
I'm using EasyTracker google analytics library and my app have multiple activities. I want
I have a little app that have by default youtube as homepage. You can
I have app in which i have recorded sound files i want that i
I have an app with a navigation bar at the top. On one view
Ok this is going to sound strange, but I have inherited an app that
I've noticed that emojis in my app have stopped displaying properly on a UIWebView
Some of the users of our Ruby on Rails app have complained that page
I'm new to Django. I have installed an external App that is in python2.6/site-packages/haystack.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.