Windows 7 Forums
Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.


Windows 7: create a popup reminder using batch file


09 Jul 2010   #1

windows 7 Home Premium
 
 
create a popup reminder using batch file

Hi there, In XP I used 2 batch files to create a popup reminder in a cmd window. I don't want to use a program like task manager as it requires to much input for the type of reminder I want. With these batch files I would run one of them, enter a time, enter a description and that was it. A cmd window would popup at the set time and show me whatever I had typed in the description. Quick and easy, no mucking around. I have tried to use them on Windows 7 but they don't seem to work. Can someone please tell me if I can do this on Windows 7 and how? Here are the details of the 2 batch files used in XP:

They both go in C:\Windows. Run setalarm.bat to create the reminder. Type time in 00:00 format and press Enter. Type description and press Enter.

1: setalarm.bat

@ECHO OFF
SETLOCAL
SET _t=%1
SET _d=%2 %3 %4 %5
SET _x=%_d: =%
IF NOT DEFINED _t (SET /P _t=Enter the time: )
IF NOT DEFINED _x (SET /p _d=Enter the description: )
IF NOT DEFINED _d (SET /p _d=Enter the description: )
ECHO. reminder at %_t% to %_d%
at \\%COMPUTERNAME% %_t% /interactive cmd /c showalarm "%_d%"

2: showalarm.bat

@echo off
cls
echo.
echo.
echo %1
echo.
echo.
pause

Cheers.

My System SpecsSystem Spec
.

19 Jul 2010   #2

windows 7 Home Premium
 
 

Oh woe is me. Can nobody help me with this?
My System SpecsSystem Spec
19 Jul 2010   #3

windows 7 Home Premium
 
 
Please help with my batch files

I am so disappointed Everyone here at sevenforums is usually soooooooo amazing but this post has had 180+ views over a week and not one reply. I'm sure this must be possible in Windows 7 but is there no-one out there who can show me how? (Or at least confirm it's possible.) Please help!! Please please please.

PS: I can run the setalarm.bat and enter the details but at the entered time, showalarm.bat doesn't show - nothing happens.
My System SpecsSystem Spec
.


19 Jul 2010   #4

Windows 7 Ultimate X64 SP1
 
 

Well kiwichick, Firstly can I apologise for not replying before, I hadnt seen this post.

I have just done a bit of research on this, and it seems while it could be done in XP, it cant be done in the same way on Vista or 7 (typical huh?)

The only workaround I can think of, is to maybe create a Scheduled Task that will open a Notepad window with your reminder on it? Sorry I cant be more help
My System SpecsSystem Spec
19 Jul 2010   #5

Windows 7 Professional 32-bit (6.1, Build 7600)
 
 

Quote   Quote: Originally Posted by severedsolo View Post

The only workaround I can think of, is to maybe create a Scheduled Task that will open a Notepad window with your reminder on it? Sorry I cant be more help
The opening of Notepad would not be needed if the bat files were entered as a scheduled task/tasks with the option Run with highest privileges. I use shortcuts to bat files which turn SRP on and off on the fly from within the Start Menu. The shortcut/bat's are much quicker than entering in Local Security to turn SRP on or off. For some reason Local Security is time consuming for me to load

Elevated Program Shortcut without UAC Prompt - Create
My System SpecsSystem Spec
19 Jul 2010   #6

windows 7 Home Premium
 
 

Hi guys thank you so so much!!!

Ok so the upshot is it can't be done by simply running the setalarm.bat. Yes, typical indeed!! As a new Windows 7 user I find some of new things added are just so awesome I get blown away. And some of the things they've taken out, changed or disabled are totally inexplicable! The number of times I've said WTF.

severedsolo: Thanks for the advice of Task Scheduler but as I originally said, the beauty of the batch files were their simplicity - double-click, type-enter, type-enter, done. Just creating the notepad reminder would take more than that.

Greg S: Are you saying that the code is correct but (referring to the link you've posted) it's a UAC problem and the batch files will work if executed another way? I don't have UAC turned on so should that even matter? I'm not sure I understand about adding the batch files to Task Scheduler because I've never used it but I'll go have a look. Any further help in the regard would be great.

Thanks again guys. SevenForums still ROCKS!!!!
My System SpecsSystem Spec
19 Jul 2010   #7

Windows 7 Professional 32-bit (6.1, Build 7600)
 
 

Quote   Quote: Originally Posted by kiwichick View Post

Greg S: Are you saying that the code is correct but (referring to the link you've posted) it's a UAC problem and the batch files will work if executed another way? I don't have UAC turned on so should that even matter? I'm not sure I understand about adding the batch files to Task Scheduler because I've never used it but I'll go have a look. Any further help in the regard would be great.

Thanks again guys. SevenForums still ROCKS!!!!
Your bat code for setting the time works for me. I do use UAC so the command console will not appear for me but I have hunch that if I create the Scheduled Task for it, it will popup.....

It appears that it will not popup, hmm

When setalarm.bat is run, it's automatically added to the scheduled tasks. When the time comes to trigger showalarm.bat, it seems to be spinning it's wheels,lol. I'll have to do some digging on this.
My System SpecsSystem Spec
20 Jul 2010   #8

windows 7 Home Premium
 
 

Thanks Greg S, You would be the absolute bomb if you could figure it out. Glad to know to care enough to try
My System SpecsSystem Spec
20 Jul 2010   #9

Windows 7 Professional 32-bit (6.1, Build 7600)
 
 

Quote   Quote: Originally Posted by kiwichick View Post
Thanks Greg S, You would be the absolute bomb if you could figure it out. Glad to know to care enough to try
Well I finally got it to run sort of. As I mentioned earlier, when you run setalarm it automatically adds a task to Task Scheduler as At1. In Task Scheduler, I double clicked the At1 and at the bottom changed the configure for: to Windows 7, Windows Server. Just above that, Change User or Group..., I added Users in an attempt to see if it would do anything. It did, but so far not enough.

create a popup reminder using batch file-untitled.png


My System SpecsSystem Spec
20 Jul 2010   #10

Windows 7 Professional 32-bit (6.1, Build 7600)
 
 

Got it to work by adding the full path to showalarm.bat.
Code:
@ECHO OFF
SETLOCAL
SET _t=%1
SET _d=%2 %3 %4 %5
SET _x=%_d: =%
IF NOT DEFINED _t (SET /P _t=Enter the time: )
IF NOT DEFINED _x (SET /p _d=Enter the description: )
IF NOT DEFINED _d (SET /p _d=Enter the description: )
ECHO. reminder at %_t% to %_d%
at \\%COMPUTERNAME% %_t% /interactive cmd /c E:\windows\showalarm "%_d%"
Name:  Untitled.png
Views: 185
Size:  42.6 KB


My System SpecsSystem Spec
Reply

 create a popup reminder using batch file




Thread Tools




Our Sites

Site Links

About Us

Find 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 07:13 PM.
Twitter Facebook Google+



Windows 7 Forums

Seven Forums Android App Seven Forums IOS App
  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33