• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: NSTimer
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSTimer


  • Subject: Re: NSTimer
  • From: Keary Suska <email@hidden>
  • Date: Thu, 4 Dec 2008 10:16:06 -0700


On Dec 4, 2008, at 4:17 AM, Mahaboob wrote:

Hi,
I need to fire the thread repeatedly in regular time intervals. So I used
the timer like:
timer = [[NSTimer scheduledTimerWithTimeInterval:(double) [txtTimeinterval
doubleValue] target:self selector:@selector(myThread:) userInfo:nil
repeats:YES]retain];


It is working but, the thread is fired only after the the time interval I
had given. But actually I need to begin the thread in 0Sec and then keep the
regular time interval. For that I used the code :

Just a note, you don't have to wait for the timer to fire, you can call -fire directly right after construction to get 0s fire.


HTH,

Keary Suska
Esoteritech, Inc.
"Demystifying technology for your home or business"

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >NSTimer (From: Mahaboob <email@hidden>)

  • Prev by Date: Re: Programmatically loading an NSImage via other field
  • Next by Date: Re: Asynchronous timers (without a run loop)
  • Previous by thread: Re: NSTimer
  • Next by thread: Webview and streaming data
  • Index(es):
    • Date
    • Thread