Results 1 to 3 of 3
  1. #1
    tgwacker is offline Novice
    Windows 7 32bit Access 2007
    Join Date
    Nov 2013
    Location
    Columbia, SC
    Posts
    9

    Entered Date storing as Time


    I have a form with a date field being entered to insert a new row into a table. Prior to inserting the data to the table, I stopped the execution on the INSERT statement and looked at the field being inserted. It has the valid date that I entered. After doing the insert, the field in the table contains a time. The table field has the following definitions:
    Data Type: Data/Time
    Format: Short Date
    Input Mask: 00/00/0000
    Show Date Picker: For Dates

    The field in the form has the following Properties:
    Format: Short Date
    Show Date Picker: For Dates
    Input Mask: 99/99/9999;0;_

    Also, when I place the cursor on the date field on the form, the Date Picker does not appear.

  2. #2
    June7's Avatar
    June7 is online now VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,900
    The Date Picker will not trigger when an Input Mask is set.

    Show the INSERT statement. Probably need # delimiters. "INSERT INTO tablename(fieldname) VALUES(#" & Me.controlname & "#)"

    Why code to create record? Why not bound form?
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #3
    tgwacker is offline Novice
    Windows 7 32bit Access 2007
    Join Date
    Nov 2013
    Location
    Columbia, SC
    Posts
    9
    Thank you.

    I removed the Input Mask and the Date Picker showed. I added the # sign to the INSERT and the date was added to the table instead of being added as a time.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 2
    Last Post: 01-25-2017, 08:36 AM
  2. Replies: 4
    Last Post: 10-13-2016, 04:06 PM
  3. Help storing Time with multiple users
    By bobrulz in forum Programming
    Replies: 1
    Last Post: 11-30-2014, 09:05 PM
  4. Storing a value with associated time
    By rikesh in forum Access
    Replies: 2
    Last Post: 03-26-2013, 07:58 AM
  5. Storing Elapsed Time in a Field
    By andybuck86 in forum Access
    Replies: 1
    Last Post: 10-08-2011, 05:07 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums