Results 1 to 3 of 3
  1. #1
    Join Date
    Aug 2009
    Posts
    6

    Unanswered: maintain date format

    I have a form that creates convoy numbers the format should be FC "JulianDate" # of convoy(FC 09 123 01) . I use an afterupdate event to create the field for the julian date and the convoy number is created in a module. the problem is when the convoy number is created the date is fomatted mm/dd/yyyy so the it looks like (FC 05/03/2009 01). I can't figure out how to maintain the formating from the julian date field to the convoynumber field. Any help would be greatly appreciated.

  2. #2
    Join Date
    May 2009
    Posts
    258
    Welcome to the forums!

    Have you tried using the Format function?

    The following will get you what you need, but will not include leading zeroes on the day of the year:
    Code:
    "FC " & Format(date_value, "yy y") & " 01"
    The following will allow for leading zeroes in the day of the year:
    Code:
    "FC " & Format(date_value, "yy") & " " & Format(Format(date_value, "y"), "000") & " 01"
    Regards,

    Ax

  3. #3
    Join Date
    Aug 2009
    Posts
    6
    It worked.

    Thank you

Posting Permissions

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