Alpha Video Training
Results 1 to 11 of 11

Thread: System Time

  1. #1
    Member
    Real Name
    Dylan Cothill
    Join Date
    Mar 2009
    Posts
    96

    Default System Time

    I have Alpha 5 auto completing a field with system time using time()

    For some reason it is recording 14:12 pm or 26:12
    Very odd.
    In the actual table it is displayed: 00/00/0000 14:12:11 51 pm

    I went to code editor/interactive window and typed ? time() and it returned "18:12:13"

    Can anyone advise on this weird issue?

    Thanks

  2. #2
    Volunteer Moderator
    Real Name
    Alan Buchholz
    Join Date
    Oct 2000
    Location
    Delavan, Wisconsin
    Posts
    9,644

    Default Re: System Time

    Look at the display format that is assign to the field as part of the component.

    You can modify the format there..
    Al Buchholz
    Bookwood Systems, LTD
    Weekly QReportBuilder Webinars Thursday 1 pm CST

    Occam's Razor - KISS
    Normalize till it hurts - De-normalize till it works.
    Advice offered and questions asked in the spirit of learning how to fish is better than someone giving you a fish.
    When we triage a problem it is much easier to read sample systems than to read a mind.

  3. #3
    Member
    Real Name
    Dylan Cothill
    Join Date
    Mar 2009
    Posts
    96

    Default Re: System Time

    Quote Originally Posted by Al Buchholz View Post
    Look at the display format that is assign to the field as part of the component.

    You can modify the format there..
    Thanks for your response but it's not the time format that is the issue. The issue is the actual time. in a 12 hour clock you don't get 14:00 pm....and in a 24 hour clock you don't get 26:00

  4. #4
    Member
    Real Name
    Dylan Cothill
    Join Date
    Mar 2009
    Posts
    96

    Default Re: System Time

    Quote Originally Posted by djtreble View Post
    Thanks for your response but it's not the time format that is the issue. The issue is the actual time. in a 12 hour clock you don't get 14:00 pm....and in a 24 hour clock you don't get 26:00
    anyone?

  5. #5
    "Certified" Alphaholic
    Real Name
    Mike Christensen
    Join Date
    Nov 2005
    Location
    Michigan U.P.
    Posts
    5,937

    Default Re: System Time

    possible that your field width is such that you are just showing the right "half" of the actual time ----check your field width and see......
    Mike
    __________________________________________
    It is only when we forget all our learning that we begin to know.
    It's not what you look at that matters, it's what you see.
    Henry David Thoreau
    __________________________________________




  6. #6
    Member
    Real Name
    Dylan Cothill
    Join Date
    Mar 2009
    Posts
    96

    Default Re: System Time

    Quote Originally Posted by MikeC View Post
    possible that your field width is such that you are just showing the right "half" of the actual time ----check your field width and see......
    Thanks Mike,

    I have had a look and the width is the default set by Alpha when you choose "time" as the field type. The default set is 17 characters

  7. #7
    "Certified" Alphaholic
    Real Name
    Mike Christensen
    Join Date
    Nov 2005
    Location
    Michigan U.P.
    Posts
    5,937

    Default Re: System Time

    not the table field width.....your display width on whatever you are using to display the time.
    Mike
    __________________________________________
    It is only when we forget all our learning that we begin to know.
    It's not what you look at that matters, it's what you see.
    Henry David Thoreau
    __________________________________________




  8. #8
    Member
    Real Name
    Dylan Cothill
    Join Date
    Mar 2009
    Posts
    96

    Default Re: System Time

    Quote Originally Posted by MikeC View Post
    not the table field width.....your display width on whatever you are using to display the time.
    I am using a grid and the format is set to:
    TIME("0h:0m",<value>)

    And when it shows the example, it is correct.

    When I go into the actual table to view the time recorded, it's there that it's incorrect. So that's why it's showing incorrectly in the grid.

    But how is it recording the time so weirdly?

    I've tried two entries where it captured the time within 30 seconds of each other, and the two times displayed between the two are:

    26:15
    23:32

  9. #9
    Member
    Real Name
    Dylan Cothill
    Join Date
    Mar 2009
    Posts
    96

    Default Re: System Time

    Anyone else got ideas?

  10. #10
    Member
    Real Name
    Dylan Cothill
    Join Date
    Mar 2009
    Posts
    96

    Default Re: System Time

    Quote Originally Posted by djtreble View Post
    Anyone else got ideas?
    The reason for this, somehow, is the field is set as a "time" type but the system time doesn't give time in that format when you request time().

    So I chaged the field types to "character" and it works now

  11. #11
    "Certified" Alphaholic Stan Mathews's Avatar
    Real Name
    Stan Mathews
    Join Date
    Apr 2000
    Location
    Bowling Green, KY
    Posts
    25,119

    Default Re: System Time

    the system time doesn't give time in that format when you request time().
    Quite true.

    Formatted_Date_Time as C = TIME( [ Format_String as C [, Date_Time_Value as T ]] )
    There can be only one.

Similar Threads

  1. Change Time system for command A5
    By fernandopm in forum Alpha Five Version 9 - Desktop Applications
    Replies: 3
    Last Post: 08-23-2009, 10:07 PM
  2. system menu - system toolbar
    By Doug Chanley in forum Alpha Five Version 5
    Replies: 2
    Last Post: 12-01-2003, 05:26 PM
  3. Ensuring correct system time and date
    By Robin Sculthorpe in forum Alpha Five Version 5
    Replies: 29
    Last Post: 10-29-2003, 05:04 PM
  4. System time field
    By mike Greco in forum Upgrading to Alpha Five from Alpha Four
    Replies: 2
    Last Post: 10-13-2003, 01:31 PM
  5. System Time
    By gerard1014 in forum Alpha Five Version 4
    Replies: 8
    Last Post: 01-28-2002, 07:36 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •