home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #31 / NN_1992_31.iso / spool / comp / sys / mac / hypercar / 4627 < prev    next >
Encoding:
Text File  |  1992-12-21  |  1.3 KB  |  42 lines

  1. Newsgroups: comp.sys.mac.hypercard
  2. Path: sparky!uunet!stanford.edu!nntp.Stanford.EDU!jessica.stanford.edu!brod
  3. From: brod@jessica.stanford.edu (Brodie Lockard)
  4. Subject: Re: Help! I need the time in my stack
  5. Message-ID: <1992Dec21.083357.8376@leland.Stanford.EDU>
  6. Sender: news@leland.Stanford.EDU (USENET News System)
  7. Organization: Academic Information Resources
  8. References: <92356.01033234A6J53@CMUVM.CSV.CMICH.EDU>
  9. Date: Mon, 21 Dec 92 08:33:57 GMT
  10. Lines: 30
  11.  
  12. In article <92356.01033234A6J53@CMUVM.CSV.CMICH.EDU> CHUCK WILLIAMS <34A6J53@CMUVM.CSV.CMICH.EDU> writes:
  13. >Hellooo netters,
  14. >
  15. >I'm thinking of creating a hypercard stack that will keep track
  16. >of the system users in the lab where I work.  To do this I want
  17. >to grab the mac's time and input it when the person logs on; I also
  18. >would like to increment the time and make an alarm when the user
  19. >exceeds the time limit.  This is a big requirement spec of mine,
  20.  
  21. In your stack script:
  22.  
  23. on openStack
  24.   global timeIn, timeLimitInMinutes
  25.   put the ticks into timeIn
  26.   put 20 into timeLimitInMinutes --or whatever you want the limit to be
  27.   ...
  28. end openStack
  29.  
  30. on idle
  31.   global timeIn, timeLimitInMinutes
  32.   if (the ticks - timeIn) / 3600 > timeLimitInMinutes then
  33.     answer "Time's up!" with "Goodbye"
  34.     go home
  35.   else
  36.     ...
  37.   end if
  38.   pass idle
  39. end idle
  40.  
  41. Brodie Lockard      brod@jessica.stanford.edu
  42.