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. General Programming
  3. C / C++ / MFC
  4. timers in a console app

timers in a console app

Scheduled Pinned Locked Moved C / C++ / MFC
questiontutorialworkspace
7 Posts 4 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.
  • E Offline
    E Offline
    eusto
    wrote on last edited by
    #1

    How do i setup timers in a console application? Is it possible? does anyone know any tutorial on this matter? Thanks

    L Z S 3 Replies Last reply
    0
    • E eusto

      How do i setup timers in a console application? Is it possible? does anyone know any tutorial on this matter? Thanks

      L Offline
      L Offline
      led mike
      wrote on last edited by
      #2

      It is fairly simple. Take a look at the MSDN documentation for CreateTimerQueueTimer()

      led mike

      E 1 Reply Last reply
      0
      • L led mike

        It is fairly simple. Take a look at the MSDN documentation for CreateTimerQueueTimer()

        led mike

        E Offline
        E Offline
        eusto
        wrote on last edited by
        #3

        Thanks! Didn't know about this one

        1 Reply Last reply
        0
        • E eusto

          How do i setup timers in a console application? Is it possible? does anyone know any tutorial on this matter? Thanks

          Z Offline
          Z Offline
          Zac Howland
          wrote on last edited by
          #4

          See here.

          If you decide to become a software engineer, you are signing up to have a 1/2" piece of silicon tell you exactly how stupid you really are for 8 hours a day, 5 days a week Zac

          L 1 Reply Last reply
          0
          • Z Zac Howland

            See here.

            If you decide to become a software engineer, you are signing up to have a 1/2" piece of silicon tell you exactly how stupid you really are for 8 hours a day, 5 days a week Zac

            L Offline
            L Offline
            led mike
            wrote on last edited by
            #5

            Second time this has happened eh? I say TimerQueueTimer and you say WaitableTimer. 6 to one tomatoes to another. :laugh:

            led mike

            Z 1 Reply Last reply
            0
            • E eusto

              How do i setup timers in a console application? Is it possible? does anyone know any tutorial on this matter? Thanks

              S Offline
              S Offline
              Stephen Hewitt
              wrote on last edited by
              #6

              You can also use SetTimer using a callback function. The only tricky bit is that you need to run a message pump as this is where timer callbacks are performed; most people don't know this and since must apps are GUI the lack causes no problems.

              Steve

              1 Reply Last reply
              0
              • L led mike

                Second time this has happened eh? I say TimerQueueTimer and you say WaitableTimer. 6 to one tomatoes to another. :laugh:

                led mike

                Z Offline
                Z Offline
                Zac Howland
                wrote on last edited by
                #7

                Either one would work ... I've just used WaitableTimers more than TimerQueues so I knew that one off-hand.

                If you decide to become a software engineer, you are signing up to have a 1/2" piece of silicon tell you exactly how stupid you really are for 8 hours a day, 5 days a week Zac

                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