|
Answer» i need a code that will set a ver (tsec) that when used it will only display the seconds of the time. Think you PLAESE HELPDisplays the current time's seconds VALUE:
echo %time:~6,2%
so...
set tsec=%time:~6,2%so then why is this not working :-? :-? :-? Code: [Select]@echo off echo Done!!! set timed=%time:~6,2% set tsec=%timed% + "5" :loop IF %time:~6,2% EQU %tsec% ( goto :end ) ELSE ( goto :loop ) :endtry ...
@echo off echo Done!!! sleep 5
What you were trying to do had little point and would have chewed CPU cycles for no reason.
And, the statement ...
set tsec=%timed% + "5"
should have READ ...
set /a tsec=%timed% + 5
Can only suggest that you read up more on the set command (set /?) and on some basic PROGRAMMING constructs.
Hope that helps.ok think you
|