Thread: System pauses

  1. #1

    System pauses

    Hi, how do I get the system to pause for a certain amount of milliseconds before moving onto the next command?

  2. #2
    Registered User
    Join Date
    Oct 2001

    I realize this isn't what you asked for...

    #include <stdio.h>
    #include <unistd.h>

    int main()
    printf("Starting delay.\n");
    printf("Ending delay.\n");

    return 0;

    this works in Linux, I don't know if windows will have the same header file. The sleep() function takes an unsigned int, and sleeps for that many SECONDS(sorry it's not milliseconds). Anyway, I hope it helps, if not I'd like to see what function does sleep for milliseconds. If anybody else knows, please post.

    Ian (:

  3. #3
    Has a Masters in B.S.
    Join Date
    Aug 2001
    sleep() is stdlib.h in MSVC i think.
    ADVISORY: This users posts are rated CP-MA, for Mature Audiences only.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. File System Implementation
    By dodgeviper in forum C Programming
    Replies: 9
    Last Post: 11-16-2007, 01:04 PM
  2. Using system icons
    By @nthony in forum Windows Programming
    Replies: 1
    Last Post: 01-13-2007, 07:56 PM
  3. Linux database system needed
    By BobS0327 in forum Tech Board
    Replies: 7
    Last Post: 06-11-2006, 03:56 PM
  4. measuring system resources used by a function
    By Aran in forum C Programming
    Replies: 1
    Last Post: 03-13-2006, 05:35 PM
  5. BIOS system and memory allocation problem
    By beely in forum Tech Board
    Replies: 9
    Last Post: 11-25-2003, 07:12 AM