Professional UI Solutions
Site Map   /  Register
 
 

Forum

Please Log In to post a new message or reply to an existing one. If you are not registered, please register.

NOTE: Some forums may be read-only if you are not currently subscribed to our technical support services.

Forums » Prof-UIS Tech Support » CExtDateBrowserWnd Collapse All
Subject Author Date
Eric guez Jun 28, 2010 - 9:51 AM

Hello,

I’m willing to use the CExtDateBrowserWnd for selecting a (possibly long) date range. For this I thought doing it by keeping the last two date clicked (and then closing the popup calendar).
Unfortunately I couldn’t find the right event callback for this type of click. As the closest one (according to the sample program) is OnDateBrowserTimeChanged(), but it’s also called when clicking on a month.

How could I achieve this ?

Technical Support Jun 30, 2010 - 11:19 AM

We think you should ignore the case when the user clicks left right arrows on the top corners of the date browser control. Your design is oriented to clicks on the exact day numbers. Alternatively you can change your design and use two date browsers for entering two dates.

Eric guez Jun 30, 2010 - 10:18 AM

Thanks for the tip. It works well except in one case: when the user changes the current month without changing ViewMode.
I’ll try to get around this with a mouse cursor hit test if there is no other way.

Technical Support Jun 29, 2010 - 9:52 AM

Yes, you should override the CExtDateBrowserWnd::OnDateBrowserTimeChanged() virtual method. Your method should use the CExtDateBrowserWnd::ViewModeGet() method to determine the current date view mode set for the CExtDateBrowserWnd control. If the current mode is CExtDateBrowserWnd::__EVM_MONTH then your method should save the clicked dates.