Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Mobile Development
  3. Mobile
  4. How can I use CeRunAppAtTime for a thread

How can I use CeRunAppAtTime for a thread

Scheduled Pinned Locked Moved Mobile
question
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    anuhoho
    wrote on last edited by
    #1

    Hi I want a thread to start after 15/20 min For that can I use CeRunAppAtTime() .If yes can anyone provide me ways to do that. Suppose this is my thread

    void main()
    {
    ..
    ..
    g_handle= ::CreateThread( NULL, 0,MyThread, NULL, 0, 0);
    ....

    }

    Now I want This MyThread to start after 15/20 min can I do that Thanks in advance

    J 1 Reply Last reply
    0
    • A anuhoho

      Hi I want a thread to start after 15/20 min For that can I use CeRunAppAtTime() .If yes can anyone provide me ways to do that. Suppose this is my thread

      void main()
      {
      ..
      ..
      g_handle= ::CreateThread( NULL, 0,MyThread, NULL, 0, 0);
      ....

      }

      Now I want This MyThread to start after 15/20 min can I do that Thanks in advance

      J Offline
      J Offline
      Joel Ivory Johnson
      wrote on last edited by
      #2

      Start your thread immediatly. When the thread starts have it to create an unnamed event. After creating the event the thread can call CeRunAppAtTime and pass the event handle. Then call the Wait function using the even't handle as athe parameter. The thread will be blocked from running until the event gets triggered. For information on using CeRunAppAtTime with an event handle please see my comment at the bottom of This MSDN Documentation page[^]


      Joel Ivory Johnson

      J2i.net | @J2iNet

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups