Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Date/Time Picker on a Toolbar
Message
De
03/05/2000 04:18:25
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Contrôles ActiveX en VFP
Divers
Thread ID:
00365095
Message ID:
00365497
Vues:
20
>>>Has anyone ever tried placing the MS Date/Time Picker control on a toolbar? When I place one on a toolbar, it's as if it is disabled, but it's not. It looks enabled, but you cannot drop it down or do anything with it.
>>>
>>>Any information is appreciated.
>>
>>
Doug,
>>It works in a toolbar too. Maybe it's really disabled. You could "copy" it on a test form to see if it works there.
>>Cetin
>
>Cetin,
>Kind of weird... but my control isn't disabled. I've tried just directly dropping an OLE Control and selected the Date/Time Picker and that didn't work. I've tried creating a class that is an OLE Control where I selected the Date/Time Picker and then dropped that on the toolbar and that didn't work either. I also have a class that dynamically creates the Date/Time Picker control at run time (work around so that I always know that I won't have a conflict with my control in regards to versions), and I dropped this on the toolbar with the same result.
>
>The control "looks" like it will work. It looks enabled, and has a date that is visible, but when I try to click on it, nothing. It's as if there is something in front of the control, but there isn't.
>
>How were you able to add the control to a toolbar? Did you verify that you could drop it down and select a date?
>
>Thanks for your input.


Doug,
For a quick test to your question all I did was :
-Create a class based on toolbar
-From controls select activex
-Drag&drop dtpicker on toolbar and size it a little
-Save
-Create a test form with a custom oToolbar property
-In init added code
this.oToolbar = newobject("myToolbar","myTest.vcx")
this.oToolbar.show()

I ran it afterwards and I could dropdown and select dates.

Do you use a container for it ? If so you might need to size conatiner dynamically. If it "seems" to be working try to press arrows for a couple of times and press enter. The date it shows should change if that's a "viewport" problem. It happened to me with container and now I size my container calculating where on the form it could expand.
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
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform