Issue with TIME fields.
Ruslan Zasukhin
sunshine at public.kherson.ua
Wed Sep 13 19:11:05 CDT 2006
On 9/13/06 4:48 PM, "Russ Tyndall" <fitzbew at nc.rr.com> wrote:
> On 9/13/06 3:36 AM, "Ruslan Zasukhin" <sunshine at public.kherson.ua> wrote:
>
>> I have check all sources and places where we assign time values,
>> I do not see how this bits can catch garbage.
>>
>> So my question to you is: WHAT WAY you have to use to assign time or
>> datetime value into database?
>
> By the way, I usually populate Date/time fields like this:
>
> Dim dateNewDate as New Date
>
> dateNewDate.Year = Val(EditField2(0).Text)
> dateNewDate.Month = Val(EditField2(1).Text)
> dateNewDate.Day = Val(EditField2(2).Text)
>
> rstCursorToChange.DateField("actiondate").Year = dateNewDate.Year
> rstCursorToChange.DateField("actiondate").Month = dateNewDate.Month
> rstCursorToChange.DateField("actiondate").Day = dateNewDate.Day
Btw, in Mantis exists request add support of Date type into V4RB.
Then last 3 lines can go as one.
Also may be even better way is:
rstCursorToChange.DateField("actiondate").SetDate(
Val(EditField2(0).Text),
Val(EditField2(1).Text),
Val(EditField2(2).Text) )
I.e. Just one command/call to engine.
--
Best regards,
Ruslan Zasukhin
VP Engineering and New Technology
Paradigma Software, Inc
Valentina - Joining Worlds of Information
http://www.paradigmasoft.com
[I feel the need: the need for speed]
More information about the Valentina
mailing list