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. how to delay in the middle of the code without cpu usage

how to delay in the middle of the code without cpu usage

Scheduled Pinned Locked Moved C / C++ / MFC
tutorial
5 Posts 3 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.
  • V Offline
    V Offline
    V_shr
    wrote on last edited by
    #1

    I want to delay in the middle of my code without cpu usage , I mean I dont want to use things like timer . if there is any function or algurithm like delay() in turbo C . thanks

    C R 2 Replies Last reply
    0
    • V V_shr

      I want to delay in the middle of my code without cpu usage , I mean I dont want to use things like timer . if there is any function or algurithm like delay() in turbo C . thanks

      C Offline
      C Offline
      Chris Losinger
      wrote on last edited by
      #2

      V_shr wrote:

      I want to delay in the middle of my code without cpu usage , I mean I dont want to use things like timer

      are you talking about the Windows timer (OnTimer, SetTimer) ? that's the simplest way to do what you describe.

      image processing toolkits | batch image processing | blogging

      V 1 Reply Last reply
      0
      • V V_shr

        I want to delay in the middle of my code without cpu usage , I mean I dont want to use things like timer . if there is any function or algurithm like delay() in turbo C . thanks

        R Offline
        R Offline
        Rage
        wrote on last edited by
        #3

        Use Sleep(delay);

        http://www.readytogiveup.com/[^] - Do something special today.

        V 1 Reply Last reply
        0
        • C Chris Losinger

          V_shr wrote:

          I want to delay in the middle of my code without cpu usage , I mean I dont want to use things like timer

          are you talking about the Windows timer (OnTimer, SetTimer) ? that's the simplest way to do what you describe.

          image processing toolkits | batch image processing | blogging

          V Offline
          V Offline
          V_shr
          wrote on last edited by
          #4

          Im talking about TTimer

          1 Reply Last reply
          0
          • R Rage

            Use Sleep(delay);

            http://www.readytogiveup.com/[^] - Do something special today.

            V Offline
            V Offline
            V_shr
            wrote on last edited by
            #5

            thanks

            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