Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
VFP 5 Date Time Picker - error 0x80020005
Message
From
01/10/2001 04:15:41
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00562267
Message ID:
00562412
Views:
16
>>>I am trying to implement the VFP 5 ActiveX Date/Time picker for the first time and the refresh is generating an error '0x80020005 Type Mismatch'.
>>>Initially, I used a date/time field as the control source with date() in the actual table, then I switched to a character containing '2001/09/29'.
>>>Can anyone offer any advice?
>>>TIA.
>>
>>Allan,
>>It doesn't accept other than datetime. Directly binding it is problematic. Use an intermediate textbox IMHO (assigning value would be via DTPicker.object.value not DTPicker.value).
>>Cetin
>
>Cetin,
>
>As you can see, I am new at this ActiveX:(!
>I do not see a 'value' property in the list of properties.

Allan,
Yes in PEM sheet it doesn't exist. But it has a value property. You can see it has a value property :
-Righclick and select 'Dtpicker properties'
or :
-Click F1 on it and in online help check its properties.
or :
-Put a textbox control on a form and datetimepicker control (dtpicker). 2 commandbuttons
1st commandbuttonclick :
ThisForm.Text1.Value = ThisForm.dtpicker.object.value
2nd button click :
ThisForm.dtpicker.object.value = thisform.text1.value

FWIW Dtpicker control is a sucker to use with VFP. Monthview is more controllable. For a sample download and check FoxyClasses samples.
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform