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

  • Home
  • SEARCH
  • 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 6101535
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T13:30:38+00:00 2026-05-23T13:30:38+00:00

I am trying to do animation. At some point I want to execute a

  • 0

I am trying to do animation. At some point I want to execute a method through NSTimer. I need to pass in 1 argument. This I do it through userInfo in NSTimer. In the selector method I am trying to access back this passed arg. But when I actually run this I get the following exception. It says invalid argument. What am I doing wrong?

“Terminating app due to uncaught
exception
‘NSInvalidArgumentException’, reason:
‘-[FLOViewController hideCellView]:
unrecognized selector sent to instance
0x1681d0′”

-(void)hideCellView:(NSTimer *)timer
{
    UITableViewCell *cellView = (UITableViewCell *)[timer userInfo];
    [cellView addSubview:self.extrasView];
    return;
}

-(IBAction)showExtras:(id)sender
{
    if(![sender isKindOfClass: [UIButton class]]) return;  // be paranoid
    self.searchResTable.scrollEnabled = NO;

    //Get the exact cell where the click happened
    UIButton *button          = sender; 
    CGPoint correctedPoint    = [button convertPoint:button.bounds.origin toView:self.searchResTable]; 
    NSIndexPath *indexPath    = [self.searchResTable indexPathForRowAtPoint:correctedPoint];
    UITableViewCell *cellView = [self.searchResTable cellForRowAtIndexPath:indexPath];

    //now run animation
    CGContextRef context      = UIGraphicsGetCurrentContext();
    [UIView beginAnimations:nil context:context];
    [UIView setAnimationTransition:UIViewAnimationTransitionFlipFromLeft 
                           forView:cellView 
                             cache:YES];
    [UIView setAnimationCurve:UIViewAnimationCurveLinear];
    [UIView setAnimationDuration:1];
    [NSTimer scheduledTimerWithTimeInterval:0.5 
                                     target:self 
                                   selector:@selector(hideCellView) 
                                   userInfo:cellView 
                                    repeats:NO];
    [UIView commitAnimations];
    return;
}
  • 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-05-23T13:30:38+00:00Added an answer on May 23, 2026 at 1:30 pm

    You have passed the wrong selector.

    selector:@selector(hideCellView) 
    

    It should be,

    selector:@selector(hideCellView:) 
    

    That said you should consider sending the index path of the table view cell rather than the cell itself as cells are reused. You can get the cell later using cellForRowAtIndexPath: method the table view in the hideCellView: method.

    If you are looking to set a delay in the animation then use the setAnimationDelay: method rather that using NSTimer.

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

Sidebar

Related Questions

I'm trying to have no animation between some of my transitions. I have this
I am trying to make some kind of animation and I want it to
I'm trying to recreate an animation (some div sliding) N times, one right after
I started some android programming and I am trying to do some animation in
I'm trying to understand some flash animation, and am having difficulty working out the
I'm trying to do some simple animation. I have a UIViewController that has two
I'm trying to accomplish some animation with sets in Raphael, but even though an
I'm trying to make some flash buttons with a mouse_over animation that plays in
I'm trying to achieve some animation using jQuery. I have it working but I'm
I'm currently trying to integrate some animation drawing code of mine into a third

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.