Re: Saving DATE

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



Sam wrote:
> I'm trying to save current DATE + 1 month to table, but it doesn't
> save it as a date format but shows something like this
> "7.83754898468115E-04" after saving. I'm using following code
>
> DoCmd.RunSQL "UPDATE Administrative" & _
> " SET Field2 = " & DateAdd("m", 1, dd) & ";"
>
> Where "dd" is defined as a DATE variable. What might be wrong? Could
> there be any optional ways of completing this? Thanks!

What DataType is Field2? Dates in Access are numbers of type Double under the
covers. If you place one in a numeric field then a number is what you will see.


--
I don't check the Email account attached
to this message. Send instead to...
RBrandt at Hunter dot com


.



Relevant Pages

  • Re: DCount
    ... I used a text box instead of Cal and it did work, so looks like some format ... > RBrandt at Hunter dot com ... Prev by Date: ...
    (microsoft.public.access.modulesdaovba)
  • Re: Saving DATE
    ... "Rick Brandt" wrote: ... > Sam wrote: ... > RBrandt at Hunter dot com ... Prev by Date: ...
    (microsoft.public.access.modulesdaovba)
  • Re: Saving DATE
    ... "Rick Brandt" wrote: ... > Sam wrote: ... > RBrandt at Hunter dot com ... Prev by Date: ...
    (microsoft.public.access.modulesdaovba)
  • Re: Saving DATE
    ... Sam wrote: ... Sounds like dd also does not have a proper date value in it. ... RBrandt at Hunter dot com ... Prev by Date: ...
    (microsoft.public.access.modulesdaovba)
  • Re: vb.net and xml file
    ... I thought Format was a good practice... ... Sam ... Prev by Date: ...
    (microsoft.public.dotnet.languages.vb)