Scheduled task message popping up in background ...


  1. Posts : 44
    windows 7
       #1

    Scheduled task message popping up in background ...


    Using the method in this post ...

    Writer I Am: Creating an Hourly Reminder in Windows

    Why is the message displaying under current windows? Is there a way to force it to the front?

    Thanks,
    Ashley
      My Computer


  2. Posts : 9,582
    Windows 8.1 Pro RTM x64
       #2

    There is a way, and that is to display the message using a batch file. For your question above, the code will be as follows:

    Code:
    @echo off
    echo Stand up, stretch, move, walk around
    pause
    Save this simple file as a batch file with the extension .bat. Give it a suitable name. The pause command holds the display, so that you have to click on it to dismiss it.

    Now, follow the instructions in the link you provided and, instead of selecting the option to Display a message, choose Start a program. In the screen that follows (see below for an example) browse to the location of the batch file you created and then click OK.

    Scheduled task message popping up in background ...-capture.png
      My Computer


  3. Posts : 44
    windows 7
    Thread Starter
       #3

    Works great with one minor issue. Is it possible to place focus on the cmd window? It pops up in front of everything else but you must click on it before you can "press any key to continue".
      My Computer


  4. Posts : 9,582
    Windows 8.1 Pro RTM x64
       #4

    I've had another look at this, and the solution is deceptively simple. It doesn't involve a batch file, rather you need to use vbScript.

    Code:
    MsgBox "Stand up, stretch, move, walk around.", vbSystemModal
    Save this simple file as a vbscript file with the extension .vbs. Give it a suitable name. Again follow the instructions in the link you provided and, instead of selecting the option to Display a message, choose Start a program. In the screen that follows (see my post above) browse to the location of the vbscript file you created and then click OK.
      My Computer


  5. Posts : 44
    windows 7
    Thread Starter
       #5

    Dwarf said:
    I've had another look at this, and the solution is deceptively simple. It doesn't involve a batch file, rather you need to use vbScript.

    Code:
    MsgBox "Stand up, stretch, move, walk around.", vbSystemModal
    Save this simple file as a vbscript file with the extension .vbs. Give it a suitable name. Again follow the instructions in the link you provided and, instead of selecting the option to Display a message, choose Start a program. In the screen that follows (see my post above) browse to the location of the vbscript file you created and then click OK.
    Perfect! Thank you immensely!! :)
      My Computer


  6. Posts : 9,582
    Windows 8.1 Pro RTM x64
       #6

    You're welcome. :)
      My Computer


 

  Related Discussions
Our Sites
Site Links
About Us
Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 22:41.
Find Us