🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: alt.lang.basic
Article #416

Re: Time restriction on data entry

#416
From: John Hutchinson
Date: Thu, 07 Jan 1993 21:25
22 lines
1488 bytes
In article 1@acad.drake.edu, jr2921r@acad.drake.edu () writes:
>I am writing a short program in QuickBasic 4.5 which requires the user to input
>an answer to a question.  However, I only want to give the user a few seconds
>to perform the data entry.  Is there an easy way to do this using the 
>INPUT statement?

I don't believe you can use INPUT for this as it ties up the system until the
user presses Return.

Rather, I think you would have to write a routine for scanning the keyboard
inside your timer loop, exiting when a keystroke is detected.  This would
work fine for single character replies, but not if the user had to type in
multiple characters.

Any other ideas from someon else?

---

___________________________ John "HUTCH" Hutchinson _________________________
_________________ Fair Dinkum Technologies     Member - IAAD  _______________
________________ "No worries, mate... it's from Fair Dinkum!" _______________
____________ email: hutch@bellman.lanl.gov   GEnie: FAIR-DINKUM _____________
Technical Details
Message-ID: <1993Jan7.212543.8012@newshost.lanl.gov>
Path: arc1-ca.pugleaf.net!sparky!uunet!cs.utexas.edu!hellgate.utah.edu!lanl!ilmen!hutch
References: <1993Jan7.091656.1@acad.drake.edu>

Show Full Headers
Complete Article Headers
Newsgroups: alt.lang.basic
Path: arc1-ca.pugleaf.net!sparky!uunet!cs.utexas.edu!hellgate.utah.edu!lanl!ilmen!hutch
From: hutch@bellman.lanl.gov (John Hutchinson)
Subject: Re: Time restriction on data entry
Message-ID: <1993Jan7.212543.8012@newshost.lanl.gov>
Sender: news@newshost.lanl.gov
Reply-To: hutch@bellman.lanl.gov
Organization: Los Alamos National Laboratory
References: <1993Jan7.091656.1@acad.drake.edu>
Date: Thu, 7 Jan 1993 21:25:43 GMT
Lines: 24