OnTimer to Often?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Jimmy

    #1

    OnTimer to Often?

    Will setting the ontimer interval to a low number cause memory problems down
    the Line? I have a text box to display the time and set the forms ontimer
    interval to 1000ms (1 second) so the box requeries every second, thus the
    time is always accurate to the second. Am I asking for trouble? Also, is
    there a way to set up the Now() function so that it doesnt display the
    seconds?


  • Rick Brandt

    #2
    Re: OnTimer to Often?

    "Jimmy" <none@none.comw rote in message
    news:YVdYg.2894 2$p86.26327@fe0 5.news.easynews .com...
    Will setting the ontimer interval to a low number cause memory problems down
    the Line? I have a text box to display the time and set the forms ontimer
    interval to 1000ms (1 second) so the box requeries every second, thus the time
    is always accurate to the second. Am I asking for trouble? Also, is there a
    way to set up the Now() function so that it doesnt display the seconds?
    There is something to be said for using Timer events sparingly as they can be a
    resource drain. You do know that every Computer already has a clock in the
    taskbar that would only be a few inches away from the one on your form right?
    If you are just doing this for "flare" I would recommend getting rid of it.

    As for the seconds you can use the format property to display the time any way
    you like.

    --
    Rick Brandt, Microsoft Access MVP
    Email (as appropriate) to...
    RBrandt at Hunter dot com


    Comment

    • Larry Linson

      #3
      Re: OnTimer to Often?

      "Jimmy" wrote
      . . . Also, is there a way to set up the Now()
      function so that it doesnt display the
      seconds?
      The Now() function does not _display_ anything; it returns a date/time
      value.

      You can use the Format property of your Control, or the Format function in
      an expression to display that returned time as you choose. A format of

      mm/dd/yyyy hh:nn

      in the Format property of a Text Box displays 10/14/2006 22:32 for me.
      Using a format of

      mm/dd/yyyy hh:nn AM/PM

      displays 10/14/2006 10:32 PM.

      There's good Help on "Format" -- put your cursor in the Format line of the
      Format tab of the property sheet for your TextBox and press F1. (With
      Access 2002, you then get a choice of formatting details. Access 2002 is the
      version to which I have immediate access as I answer this post.)

      Larry Linson


      Comment

      Working...