Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
CalDate Auto Dropdown
Message
De
17/10/2003 08:27:19
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
 
À
16/10/2003 14:41:49
Information générale
Forum:
Visual FoxPro
Catégorie:
Contrôles ActiveX en VFP
Divers
Thread ID:
00839443
Message ID:
00839680
Vues:
26
This message has been marked as the solution to the initial question of the thread.
>Does anyone know how to make the CalDate OCX open the calendar when the control gets focus or when a user clicks on it?
>
>Thanks

I don't know what the Caldate.ocx is but I found this works with Datetimepicker, Monthview controls. Should work with it too :
(Emulating a user clicking on dropdown arrow)
#define WM_LBUTTONDOWN 0x0201
#define WM_SYSKEYDOWN  0x0104
#define WM_SYSKEYUP    0x0105

#define VK_MENU 12
#define VK_DOWN 28

LOCAL lnHWND
LOCAL ARRAY arrDLL[1]
ADLLS(arrDLL)
IF ASCAN(arrDLL,'SendMessage',1,-1,1,1+2+4) = 0
	declare integer SendMessage IN WIN32API ;
		integer hwnd, integer Msg, integer Wparam, integer lParam 
endif	
lnHwnd = This.hWnd
*lnHwnd = Thisform.Oledatectrl.hWnd
SendMessage(lnHwnd,WM_LBUTTONDOWN,0,0)
SendMessage(lnHwnd,WM_SYSKEYDOWN,VK_MENU+VK_DOWN,0)
SendMessage(lnHwnd,WM_SYSKEYUP,VK_MENU+VK_DOWN,0)
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