|
Answer» [highlight]@echo off echo %time% pause set /p tim=what time do you want to wake? :
:W cls echo %time% echo %tim%:??,?? if "%time%"=="%tim%:??,??" goto x goto W
:X msg * times up! pause exit[/highlight]
i dont know what im done wrong? :S please help me :-/ :-/ :-/ im running on a windows xp professional not Ms Dos but it shuld be 4:
/meNot sure what AM/PM has to do with this. The only way out of the :W loop is if the date (%date%) is equal to some random time entered by the user (%tim%). The hardcoded 4 (echo 4:%tim%:??,??) doesn't help matters.
With Windows XP you have MANY tools available to build an alarm CLOCK. Batch code is not the best tool for this. 8-):-/ so do you say it is 100% impossible to build an alarm clock in bat? please help Edit.Quote arnt u missing the E im tim or is like that? It is supposed to be like that as ogelami declared it "set /p tim=what time do you want to wake?:".Quoteso do you say it is 100% impossible to build an alarm clock in bat? please help Not QUITE and probably EASIER than digging the Panama Canal with a spoon.
if "%time% GEQ %tim%:00:00.00 goto x
You will have to localize the time format for your area.
8-)
|