Hi, I have been coding for a number of years but cut my teeth with mud (multi-user dungeon) merc code. I have never coded a gui program before only console based applications. I have a program that I am trying to write in gui and have sort of gotten the hang of some things but I can not for the life of me figure out how to get the program to do what I need it to. My question is this.
Is there any way to make the program popup a window at a certain time?
The program is supposed to be able to take in data for call backs at a call center and put them in a file (I have done that) then read the data from the file (I have done that) and check every 15 minutes to see if the time on the call back is now or has passed and pop up a window when that is the case (How on earth do I do that?)
As far as I can tell in a gui application there is a consistent while loop:

    /* Run the message loop. It will run until GetMessage() returns 0 */
    while (GetMessage (&messages, NULL, 0, 0))
        if (NULL == hwnd || !IsDialogMessage(hwnd, &messages))
            /* Translate virtual-key messages into character messages */
            /* Send message to WindowProcedure */

I can't interupt that loop or the user can't input anything and I can't put a check in it based on time because that only triggers when someone does something in the environment. I am at a loss here. Any help or insight would be greatly appreciated.

What about SetTimer() (see Timers)?. This allows you to specify a Window handle, so a WM_TIMER message will be posted to the message loop when it expires. Keep in mind that this won't be incredibly accurate.

This article has been dead for over six months. Start a new discussion instead.