PC Review


Reply
Thread Tools Rate Thread

DatePicker Dropdown

 
 
Vayse
Guest
Posts: n/a
 
      21st Dec 2005
Hi
Is there a way to make the picker drop down through code?
Thanks
Vayse


 
Reply With Quote
 
 
 
 
Claes Bergefall
Guest
Posts: n/a
 
      22nd Dec 2005
There isn't any native Win32 message or method to do it, but the following
is a workaround:

DateTimePicker1.Focus()
SendKeys.SendWait("%{DOWN}")

Basically it emulates a user pressing the button.

/claes

"Vayse" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Hi
> Is there a way to make the picker drop down through code?
> Thanks
> Vayse
>
>



 
Reply With Quote
 
Peter Huang [MSFT]
Guest
Posts: n/a
 
      22nd Dec 2005
Hi

From your description, I understand that you are using the
System.Windows.Forms.DateTimePicker, and you want to show the Calendar by
code.
Have I fully understood you? If there is anything I misunderstood, please
feel free to let me know.

Based on my research, the DateTimePicker control, did not expose such
interface for us to use for showing the Calendar. It only expose to the UI
interactive when you click the arrow in the control.

As a workaround, I think you may try to show another MonthCalendar control
in the proper place and interactive it with DateTimePicker.
e.g. When someone click one date 2,5, 2005 ,we can set it via the code
below.
Me.DateTimePicker1.Value = New Date(2002, 2, 5)

Best regards,

Peter Huang
Microsoft Online Partner Support

Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Datepicker =?Utf-8?B?Sm9obkc=?= Microsoft Outlook Form Programming 9 28th Sep 2006 08:25 PM
Q: DatePicker G .Net Microsoft VB .NET 2 1st Apr 2006 11:35 AM
DatePicker Steve Microsoft Excel Programming 0 14th Mar 2006 02:12 AM
Re: DatePicker? clintonG Microsoft ASP .NET 0 27th Aug 2005 04:47 PM
datepicker! ashoo Microsoft ADO .NET 1 10th Nov 2003 07:23 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 03:50 PM.