Results 1 to 3 of 3
  1. #1
    4 Star Lounger
    Join Date
    Jun 2001
    Location
    Indianapolis, Indiana, USA
    Posts
    527
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Date/Time string (A2K / Win2K)

    Hello All,
    I need to take two fields, one contains a date (3/13/02) and the other contains a time (08:00) and combine these to form a string of "3/31/02 08:00". Does anyone know how to do this?

    Thanks,
    Mark Santos

  2. #2
    3 Star Lounger
    Join Date
    Dec 2001
    Location
    Nevada, USA
    Posts
    207
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Date/Time string (A2K / Win2K)

    I'm fairly new at this, but I would imagine that you could concatenate the two fields - something like the following:

    strBoth = strDate & strTime

    Hope this helps.
    Carol W.

  3. #3
    4 Star Lounger
    Join Date
    Feb 2001
    Location
    Richland, Washington, USA
    Posts
    407
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Date/Time string (A2K / Win2K)

    If they are already strings, then strDate & " " & strTime will work fine. If they both are a Date/Time data type, then use the function Format(dteDate + dteTime, "mm/dd/yy hh:mm"). This will work if your date is just the date (no fractional part that denotes the time of day) and your time is just the time of day (i.e., a fraction of a day) and not a full date value just being displayed as the time of day.

Posting Permissions

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