Showing posts with label menu. Show all posts
Showing posts with label menu. Show all posts

Wednesday, March 28, 2012

System.Web.UI.WebControls.Menu and UpdatePanels / WebParts

Hi,

(using April version of Atlas)
I have a web form with a script manager, a web part manager, a menu and a web part zone with a generic web part in it. An update panel is around the web part manager and the web part zone. When I click on the arrow for the popup web part menu and chose for example "minimize", everything works fine for the first time, until the web part is rendered: When I want to click once again on the arrow for the popup web part menu, nothing happens anymore (nothing = no popup of the menu). This is just because of the System.Web.UI.WebControls.Menu on the page. When I remove the System.Web.UI.WebControls.Menu, everything works normal.

I made a sample code, to reproduce the problem:

<%@dotnet.itags.org. Page Language="VB" AutoEventWireup="true" CodeFile="Default.aspx.vb"Inherits="_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"> <atlas:ScriptManager ID="ScriptManager1" runat="server" EnablePartialRendering="true"/> <div> <atlas:UpdatePanel ID="UpdatePanel1" runat="server"> <ContentTemplate> <asp:WebPartManager ID="WebPartManager1" runat="server"> </asp:WebPartManager> </ContentTemplate> </atlas:UpdatePanel> <br /> <asp:Menu ID="Menu1" runat="server" Orientation="Horizontal"> <Items> <asp:MenuItem Text="Neues Element" Value="Neues Element"> <asp:MenuItem Text="Neues Element" Value="Neues Element"> <asp:MenuItem Text="Neues Element" Value="Neues Element"></asp:MenuItem> </asp:MenuItem> <asp:MenuItem Text="Neues Element" Value="Neues Element"></asp:MenuItem> </asp:MenuItem> <asp:MenuItem Text="Neues Element" Value="Neues Element"> <asp:MenuItem Text="Neues Element" Value="Neues Element"></asp:MenuItem> </asp:MenuItem> </Items> </asp:Menu> <br />  </div> <atlas:UpdatePanel ID="UpdatePanel2" runat="server"> <ContentTemplate> <asp:WebPartZone ID="WebPartZone1" runat="server"> <ZoneTemplate> <asp:Calendar ID="Calendar1" runat="server"></asp:Calendar> </ZoneTemplate> </asp:WebPartZone> </ContentTemplate> </atlas:UpdatePanel> </form> </body></html>

ASH123,

I am having the same issue. I found that if you set WebPartVerbRenderMode to TitleBar, you are allowed to minimize/restore the webpart multiple times.

Did you ever find a solution that doesn't involve this work around?

Thanks

Monday, March 26, 2012

TAB control is hidden on IE7

I've found a strange problem that occured only on IE7

I have a wep page (MAINPAGE) that containt an IFRAME. This page is use to put our menu. The content of our website is display inside the iframe. So here is the problem. I have made some page with the new tab control. I will call those page PAGE1 and PAGE2. So if i put a hyperlink in PAGE1 to open PAGE2 everything is working fine. In our menu i use this:

"window.frames('fraMain').location.href = '" & row("URL").ToString & "';"

This is is code for the event onclick in our menu. So when i use this code to open either PAGE1 or PAGE2 the tab control is not displayed. I've got a javascript error "unspecified error" and if i look at the source code this is what the tab control looks like:

<div id="ctl00_Contenu_TABGENERAL" class="ajax__tab_Orchestra"style="visibility:hidden;">

So there is avisibility:hidden add to the code. This only occured on IE7 and when my pages are called using this line of code "window.frames('fraMain').location.href = '" & row("URL").ToString & "';".

We've been using this line of code for years and never have any problem with any other pages that don't containt the TAB control.

Any idea ?

I've made some other test and i notice that the problem only occured the first time i open the page with our menu. So if i click on our menu to open the page the Tab control is not displayed. Then if i click again the tab control work just fine. I don't have this problem with Firefox.