Results 1 to 9 of 9
  1. #1
    Join Date
    May 2002
    Posts
    395

    Unanswered: date format question

    How could have the date format as 09/27/2002 instead of 09/27/02?
    I have the property set as short date and format as 99/99/0000 in Tbl, in txtbx of the form and in txtbx of the report, but it still prints out 09/27/02.

    Why?

    Thanks!

  2. #2
    Join Date
    Mar 2002
    Location
    Sacramento, CA
    Posts
    120

    Maybe this'll work

    Instead of Format = Short Date try:

    Format = mm/dd/yyyy

    Let us know if this helps.

    Michael

  3. #3
    Join Date
    May 2002
    Posts
    395
    It does work in the txtbxes on the report where the record source is a query based on a table. However, on the same report the txtbxes with the control source that is a form, the date format didn't change.

    The report properties set for Startdate textbox as follow:
    Name: txtbxStartdate
    control source: =[Forms]![dates]![startdate]
    Format: mm/dd/yyyy
    input mask: 99/99/0000

    The form properties for Startdate textbox :
    Name: startdate
    control source: -
    format: mm/dd/yyyy
    input mask: 99/99/0000

    What am I missing?

    Thanks!

  4. #4
    Join Date
    Mar 2002
    Location
    Sacramento, CA
    Posts
    120

    Table

    Is there a "Startdate" field in your table?
    Are the properties set there?

    Michael

  5. #5
    Join Date
    May 2002
    Posts
    395
    No, the Startdate is not a field in the table. The Startdate is a textbox on a form. There are actually two textboxes on the form where the user enters the start date and ending date for report, then a report can be generated. (The textboxes on the form do not control source because they require user to enter the dates).

    These textboxes properties are set up the same on the form and on the report.

    I appreciate your help.

  6. #6
    Join Date
    Sep 2002
    Location
    Coventry, Warwickshire, UK
    Posts
    74
    The way dates are usually displayed on forms and in datasheets when looking at tables is taken from the Regional settings in Control panel. Have a look there to see if it is set to mm/dd/yy format.
    Roger Hampson
    XI - ecs (UK) Ltd

  7. #7
    Join Date
    May 2002
    Posts
    395

    date formatting

    Thanks for all your help!
    Unfortunately the problem lies on a function call to other date conversion sub procedures that looks extremely complicated.

    Still, Thanks for your help.

  8. #8
    Join Date
    Oct 2002
    Location
    England
    Posts
    3

    Re: date format question

    Format(mydate,"dd/mm/yy")

  9. #9
    Join Date
    May 2002
    Posts
    395

    date format

    Thanks! I'll look into it.

Posting Permissions

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