Loading ...
Sorry, an error occurred while loading the content.

Launching timer events from a clipbar

Expand Messages
  • Jody
    Hi John, Yes, I did mean to the discussion list. I m a believer in two heads are better than one, at least mine. ;) Perhaps some others might have some
    Message 1 of 1 , Aug 7, 2001
    • 0 Attachment
      Hi John,

      Yes, I did mean to the discussion list. I'm a believer in "two
      heads are better than one," at least mine. ;) Perhaps some
      others might have some input for you; I can only suggest a few
      things to try.

      You do need to have the Clipbook open when using the Timer
      events; that's the way it is. Try to use the Library from the
      Clipbar by using the LoadLibrary command so that the Library will
      become active and set the focus to the Library. I'm not sure it
      will work because the Clipbar works like a ^!FarClip in that the
      Clips are loaded into memory rather than running directly from
      the Clipbook. You might also try loading any Library (small) and
      then load your timer Library. I don't know if the second Library
      will be run in memory or from the Library. You should be able to
      Hide the Clipbook.

      ^!SetFocus Clipbook
      ^!ShowClipbook False

      If it does work, you can set the current active Library in a
      variable and then activate it after you start your timer.

      John wrote:
      When you asked me to send my clip to the list, I assume you meant
      to the discussion group? If not please let me know via my normal
      email address of John@... and I'll zip it and send it to
      wherever you ask me to.. In my original message post to the clips
      discussion group I pretty much had the clip there, but below, but
      here is the latest version of it:

      Thanks,

      John Zeman

      ********************

      Alarm Clock Timer
      ; THIS ALARM CLOCK CLIP WORKS WHEN STARTED FROM A CLIP LIBRARY.
      ; AFTER STARTING IT, OTHER LIBRARIES CAN BE SWITCHED TO AND IT STILL
      RUNS
      ; BUT IF THE CLIPBOOK IS CLOSED, IT STOPS
      ; IT ALSO WILL NOT RUN WHEN LAUNCHED FROM THE CLIPBAR

      ; CLEAR VARIABLES
      ^!ClearVariable %p_Alarm%
      ^!ClearVariable %p_AlarmMessage%
      ^!ClearVariable %p_AlarmCheckInterval%

      ; INPUT THE TIME FOR THE ALARM
      ^!Set %p_Alarm%=^?{(M="00:00") Enter Time HHMM=}
      ^!Set %p_AlarmMessage%=^?{Enter the message to display when the alarm
      triggers=}
      ^!Set %x%=^?{Enter how often to check the alarm in minutes=_1|5|10}
      ; CHANGE THE MINUTES ENTERED ABOVE INTO MILLISECONDS
      ^!Set %p_AlarmCheckInterval%=^$Calc(^%x%*60000)$

      ^!Info The alarm is set for: ^%p_Alarm%

      ^!TimerStart ^%p_AlarmCheckInterval%
      ^!TimerPlay Comparator


      ; THE SECOND CLIP THAT IS CALLED BY THE ABOVE ONE, IS NEXT

      Comparator

      ; BEGIN TEMPORARY MESSAGES THAT WILL BE REMOVED ONCE THE CLIP IS
      DEBUGGED
      ^!StatusShow Checking Alarm ^%p_Alarm% -> ^$GetDate(hh:nn:ss)$
      ^!Delay 20
      ^!StatusClose
      ; END TEMPORARY MESSAGES THAT WILL BE REMOVED ONCE THE CLIP IS
      DEBUGGED

      ^!If "^%p_Alarm%" >= "^$GetDate(hh:nn:ss)$" End ELSE Ring

      :Ring
      ^!TimerStop
      ^!Info The alarm was set for: ^%p_Alarm%^P^PThe message was: ^%
      p_AlarmMessage%^P^PThe Alarm Timer has been stopped at: ^$GetDate
      (hh:nn:ss)$

      Happy Clip'n!
      Jody

      http://www.notetab.net

      Subscribe, UnSubscribe, Options
      mailto:Ntb-Clips-Subscribe@yahoogroups.com
      mailto:Ntb-Clips-UnSubscribe@yahoogroups.com
      http://www.egroups.com/group/ntb-clips
    Your message has been successfully submitted and would be delivered to recipients shortly.