Sunday, March 11, 2012

Dropdown lists float over CalendarExtender (IE6)

I should note that the above did not correct the problem. I'm currently attempting to implement an iframe hack via js. If anyone knows a different solution I'd appreciate it...

Why do you have a PopupControlExtender? Removing it per the below sample works fine for me in IE7:

 <div> DOB<br /> <asp:TextBox ID="txtDOB" runat="server" Width="110px" /> <asp:Image ID="imgDOB" runat="server" ImageUrl="~/img/calendar.png" /> <ajx:CalendarExtender ID="ceDOB" runat="server" TargetControlID="txtDOB" PopupButtonID="imgDOB" Format="MM/dd/yyyy" /> <br /> <asp:DropDownList runat="server"> <asp:ListItem Text="Item" /> </asp:DropDownList> </div>

...that's why I noted the problem was in IE6...

This is nothing new...there is a known issue with a div when it used as a "menu" or popup and it happens to be placed over a dropdown list, the drop down list floats on top of the div. The only solution I've found is to use javascript to place an iframe behind the div that is the same size and same position, but the calendar control div has no ID and thus I cannot get the size or position from it...or at least I don't know how...

As you stated, it is not a problem in IE7, but I'm not in a position to be able to upgrade all our computers to IE7.

The popup control extender was merely an attempt to see if it would correct the problem, my original code did not include that control as it is not necessary.

I'll probably end up creating my own calendar popup control (similar to the one used to demonstrate the popup control extender) by using an update panel and popupcontrol extender, I just like the functionality of the new built in calendar extender and wondered if anyone had any ideas.


Sorry, I missed that you reported this in IE6. However, Calendar works okay for us in IE6, too. Please see if the discussion in the following thread describes your situation. In it, IE6 and IE7 work fine with a simple sample, but the actual usage is more complex and demonstrates this problem, though it's due to HTML/CSS rules rather than a Calendar bug: http://forums.asp.net/thread/1550925.aspx

No comments:

Post a Comment