PDA

Click to See Complete Forum and Search --> : Writing to DateTime type in Access!


Pallex
Sep 26th, 2000, 11:41 AM
How?!
I can write date, or time, but not both. I`ve not tried reading yet.

Doesnt appear to be any help online, or on the net.

I`ve tried formatting a string containing both time and date but still i cant do it!

Any ideas?

Thanks,
Alex.

Chuck Sweet
Sep 26th, 2000, 01:55 PM
So, you're want to combine a date and time to get one value that you can write into an access database? There are several ways:

Change both into strings and use the & and a space:

cdate(cstr(dDate) & " " & cstr(dTime))

or you could:

dFinal = dDate + dTime

because the dDate is whole numbers and the time is on the right side of the decimal (ie. fractional).

Basically, combine the two before putting them into the database.

Is that what you're asking?
chuck