home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   alt.msdos.batch.nt      Fun with Windows NT batch files      68,980 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 67,327 of 68,980   
   Tom Del Rosso to Herbert Kleebauer   
   Re: Keyboard input without pause   
   20 Oct 18 16:59:02   
   
   From: fizzbintuesday@that-google-mail-domain.com   
      
   Herbert Kleebauer wrote:   
   > On 16.10.2018 16:40, Tom Del Rosso wrote:   
   >> I want to break out of a loop without ctrl-c.  Do you know any   
   >> utility that can sense keyboard input without pausing?  Any key will   
   >> do, even sensing a shift key.  That might work best in fact.   
   >   
   > Start another cmd console:   
   >   
   > @echo off   
   > if exist pause.txt del pause.txt   
   > start cmd /c pause^&echo.^>pause.txt   
   >   
   > set n=0   
   > set m=1   
   >   
   >> loop   
   > if not exist pause.txt goto :skip   
   > pause   
   > del pause.txt   
   > start cmd /c pause^&echo.^>pause.txt   
   >> skip   
   > for /l  %%i in (0,1,%n%) do set /p =. echo o   
   > set /a n=n+m   
   > if %n%==60 set m=-1   
   > if %n%==0  set m=1   
   >   
   > goto :loop   
      
   Cute, but I want to exit the loop, not pause it.  And within only a   
   single window.  I suppose I have to add another switched option to the   
   input utility I wrote in 1990.   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca