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 7036877
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T01:28:35+00:00 2026-05-28T01:28:35+00:00

Possible Duplicate: NSTimer doesn't stop I am using [NSThread exit] to leave the NSTimer

  • 0

Possible Duplicate:
NSTimer doesn't stop

I am using [NSThread exit] to leave the NSTimer thread.
It stops the application entirely.

How do you stop or exit NSTimer thread?

  • 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-28T01:28:35+00:00Added an answer on May 28, 2026 at 1:28 am

    If you want to definitely stop a NSTimer you may use

    [timer invalidate];
    

    However, if you want to temporary prevent the timer to fire you may consider using

    [timer setFireDate:[NSDate distantFuture]];
    

    From Apple Documentation:

    Once scheduled on a run loop, the timer fires at the specified interval until it is invalidated. A non-repeating timer invalidates itself immediately after it fires. However, for a repeating timer, you must invalidate the timer object yourself by calling its invalidate method. Calling this method requests the removal of the timer from the current run loop; as a result, you should always call the invalidate method from the same thread on which the timer was installed. Invalidating the timer immediately disables it so that it no longer affects the run loop. The run loop then removes and releases the timer, either just before the invalidate method returns or at some later point. Once invalidated, timer objects cannot be reused.

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

Sidebar

Related Questions

Possible Duplicate: NSTimer doesn't stop I am using a NSTimer to update the value
Possible Duplicate: NSTimer doesn't stop How can I stop / invalidate a NSTimer?? Below
Possible Duplicate: NSTimer doesn't stop I have this code: [NSTimer scheduledTimerWithTimeInterval:110.0 target:self selector:@selector(targetMethod:) userInfo:nil
Possible Duplicate: NSTimer doesn't stop I am having a hard time stopping my timer,
Possible Duplicate: How do you send email from a Java app using Gmail? How
Possible Duplicate: thread with multiple parameters How does one thread a sub with two
Possible Duplicate: Reading through file using ifstream I'm trying to find a way to
Possible Duplicate: Filetype association with application (C#) I'm writing a C# Windows app to
Possible Duplicate: how to use foursquare API in android application? This is a question
Possible Duplicate: UIScrollView pauses NSTimer until scrolling finishes I have a scrollview and a

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.