Difference between revisions of "Calendar"

From Team Developer SqlWindows Wiki
Jump to: navigation, search
(Added tip on fixing cCalendarDropDown multi-monitor issue)
m
Line 1: Line 1:
'''This page covers VT Calendar tips & tricks.'''
+
{{PageHeader|VisualToolchest Calendar Control}}
 +
 
  
 
__TOC__
 
__TOC__
<br>
+
 
  
 
<!------------------------------------------------------------------------------------------------------------------------------>
 
<!------------------------------------------------------------------------------------------------------------------------------>
Line 10: Line 11:
 
not displayed below the datefield but on the main monitor.<br>
 
not displayed below the datefield but on the main monitor.<br>
 
This issue occurs on all TD versions (up to TD6.0) !<br>
 
This issue occurs on all TD versions (up to TD6.0) !<br>
<br>
+
 
 +
 
 
[[Image:CCalendarDropDownFix.png‎]]
 
[[Image:CCalendarDropDownFix.png‎]]
<br>
+
 
 +
 
 
The workaround is to reposition the calendar popup window to the correct location on screen at the time it is displayed.<br>
 
The workaround is to reposition the calendar popup window to the correct location on screen at the time it is displayed.<br>
 
Look at the sample and locate the messages section of the custom control class. There the window handle of the popup window<br>
 
Look at the sample and locate the messages section of the custom control class. There the window handle of the popup window<br>
 
is retrieved and used to reposition it to the parent date-field.<br>
 
is retrieved and used to reposition it to the parent date-field.<br>
<br>
 
  
Here you can download the sample:
+
 
*[http://samples.tdcommunity.net/index.php?dir=&file=cCalendarDropDown_multimonitor_fix.zip cCalendarDropDown_multimonitor_fix.zip]<br>
+
Here you can download the sample:<br>
 +
{{Download
 +
|URL=http://samples.tdcommunity.net/index.php?dir=&file=cCalendarDropDown_multimonitor_fix.zip
 +
|TEXT=cCalendarDropDown_multimonitor_fix.zip
 +
}}
 
<br>
 
<br>
 
<br>
 
<br>

Revision as of 12:01, 12 July 2013

VisualToolchest Calendar Control


Contents


Pointer2.png cCalendarDropDown multi-monitor fix Pointer.png

The calendar popup window is normally presented below the corresponding date-field when clicking on the dropdown button.
But when using a multi-monitor setup and the parent window is on another monitor than the main one, the popup calendar is
not displayed below the datefield but on the main monitor.
This issue occurs on all TD versions (up to TD6.0) !


CCalendarDropDownFix.png


The workaround is to reposition the calendar popup window to the correct location on screen at the time it is displayed.
Look at the sample and locate the messages section of the custom control class. There the window handle of the popup window
is retrieved and used to reposition it to the parent date-field.


Here you can download the sample:
Down.png cCalendarDropDown_multimonitor_fix.zip