Please take a look at the sample page at the bottom of this post. (There is nothing worthwhile in the code behind.)
When viewing this page with Firefox, Safari or Opera, the page behaves correctly. However, when viewing the page with IE6 or IE7, after clicking the image to show the calendar popup, the select list will get shifted down in the page. I have determined that if I remove the MaskedEditValidator from its location in the page (either to outside that div or remove it entirely), the caledar popup will NOT shift the select list, at least with IE7.
The obvious workaround is to move the MaskedEditValidator, since it's not being displayed anyway. However, I was planning to wrap all of these controls into a single control that can be reused across our site, so I will have to keep the controls together.
We are using the ASP.NET 2.0 version of build 20229, but as far as i can tell, neither the CalendarExtender's nor the MaskedEditValidator's code has changed since this version.
On a side note, I also viewed this page with IE8 and the content didn't shift down, but the top of the calendar popup appeared halfway up the text box instead of below it.
Thanks!
<%@ Page Language="vb" AutoEventWireup="false" CodeBehind="Default.aspx.vb" Inherits="WebApplication._Default" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<title>Untitled Page</title>
</head>
<body>
<form id="form1" runat="server">
<asp:ScriptManager runat="server" />
<div>
<span style="white-space: nowrap;">
<asp:TextBox ID="DateTextBox" runat="server" Columns="10" MaxLength="10" />
<ajaxtoolkit:MaskedEditExtender ID="DateTextBoxMaskExtender" runat="server" TargetControlID="DateTextBox" Mask="99/99/9999" MaskType="Date" ClearTextOnInvalid="true" ClearMaskOnLostFocus="false" />
<ajaxtoolkit:MaskedEditValidator runat="server" ControlToValidate="DateTextBox" ControlExtender="DateTextBoxMaskExtender" IsValidEmpty="true" Display="None" />
<asp:ImageButton ID="ToggleImage" runat="server" ImageUrl="~/DatePickerButton.gif" ImageAlign="AbsMiddle" />
<ajaxtoolkit:CalendarExtender runat="server" TargetControlID="DateTextBox" PopupButtonID="ToggleImage" PopupPosition="BottomLeft" />
</span>
</div>
<div>
<asp:DropDownList runat="server">
<asp:ListItem Text="Test" />
</asp:DropDownList>
</div>
</form>
</body>
</html>