Is there a time picker?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Seth Schrock
    Recognized Expert Specialist
    • Dec 2010
    • 2965

    Is there a time picker?

    I'm currently working moving a process from Excel to Access. In the existing Excel sheet, there are two fields: Completed Date and Completed Time. Completed Date works great with the Date Picker in Access. Is there a similar thing for times?
  • NeoPa
    Recognized Expert Moderator MVP
    • Oct 2006
    • 32653

    #2
    I don't think so Seth. There wouldn't be a need as far as I can see. The need for a date picker is mainly due to the non-standard nature of dates, whereas times follow strict rules quite well.

    If you must have something though, a TextBox displaying a value with some small buttons around it to up and down the hours and minutes should be easy enough to set up using standard form tools.

    Comment

    • TheSmileyCoder
      Recognized Expert Moderator Top Contributor
      • Dec 2009
      • 2322

      #3
      Now I don't know what you are recording, but a textbox with the default set to the current time might be a good start, and then as NeoPa said buttons to increase/decrease the actual hours/minutes.

      Comment

      • zmbd
        Recognized Expert Moderator Expert
        • Mar 2012
        • 5501

        #4
        There is an active-x control available in V2010 that has the ability to handle the time.
        Two drawbacks:
        (1) The popup portion is still just the month; however, if you tab into the control you can use the up/down arrows to step thru the date and time - not intuitive as there's nothing indicating that one can do this, I discovered it by playing with it.
        (2) If the *.DLL (sorry don't remember the name) isn't installed correctly... or isn't installed as on one client pc... then the control breaks and it doesn't even let you know there's an issue... it just shows blank and the user can't do anything with the control. Took 2 days to discover that issue... I.T. fixed by a clean install of Office.

        As a work around:
        I've made a popup that does this trick and with the new date picker it works well as there's less coding to get the date in the correct format. Unbound form. Unbound Txtbox set to date format. two unbound cbo with the record source as list and entered the hours into one and minutes into the second and set the list length to show them all (used 24 hour clock otherwise you'll need another for am/pm) I have also done this using the spinner controls however most of my users like the cbo better.
        The on open event pulls the system clock and pre-enters the current date and selects the hour and minute.
        Command button to close has the event to enter the time into the related field.
        In the related field I use the old docmd to open the form passing the field table and name as open arg on the double-click event.
        I've also played with a custom event when I like.

        Well an all day trip so I wont be able to get back this until later
        Last edited by zmbd; Oct 27 '12, 07:25 AM. Reason: (Z)spelling

        Comment

        • Seth Schrock
          Recognized Expert Specialist
          • Dec 2010
          • 2965

          #5
          I think that I will go with an Input Mask instead. I just discovered that there was an input mask for times. The users currently have to type it in so having the ":" already inserted should be enough for them. Thanks for all the input.

          Comment

          Working...