This is a migrated thread and some comments may be shown as answers.

IE7: Client nested view toggle - button not hiding

2 Answers 35 Views
Button
This is a migrated thread and some comments may be shown as answers.
Adam
Top achievements
Rank 1
Adam asked on 06 Jun 2011, 08:15 PM
In IE7, if a rad button appears inside a RadGrid nested view template with HierarchyLoadMode="Client", the button does not hide after the details are shown then toggled off again:

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="repro.aspx.cs" Inherits="_Default" %>
<!doctype html>
<html>
<head><title></title></head>
<body>
  <form id="form1" runat="server">
  <telerik:RadScriptManager ID="RadScriptManager1" runat="server"></telerik:RadScriptManager>  
  <telerik:RadGrid ID="RadGrid1" runat="server" CellSpacing="0" GridLines="None">
    <MasterTableView HierarchyLoadMode="Client">
      <NestedViewTemplate>
        <telerik:RadButton ID="RadButton1" runat="server" Text="RadButton">
        </telerik:RadButton>
      </NestedViewTemplate>       
    </MasterTableView>
  </telerik:RadGrid>
</form>
</body>
</html>

using System;
public partial class _Default : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        RadGrid1.DataSource = new string[] { "item1", "item2" };
    }
}

Anything special I should be doing?

2 Answers, 1 is accepted

Sort by
0
Pero
Telerik team
answered on 08 Jun 2011, 08:09 AM
Hello Adam,

This issue is a well known problem in IE7 browser with elements which have position: relative applied. The RadButton element needs position relative to correctly place the icons when they are used. We have explained this issue in an article from our online documentation: http://www.telerik.com/help/aspnet-ajax/radbutton-known-issues-ie6-ie7.html. To fix the issue please set posRelativeClass to the CssClass property of the RadGrid's MasterTableView, and apply the following CSS code:
<style type="text/css">
    *+html .posRelativeClass tr
    {
        position: relative;
    }
</style>


All the best,
Pero
the Telerik team

Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.

0
Adam
Top achievements
Rank 1
answered on 08 Jun 2011, 07:51 PM
Hi Pero, I had read that article but from it's wording it sounded like it only affects buttons placed inside a element with scroll bars which didn't seem to be the case here.
I'll try your recommendation though, seems to make sense.
 
I was also incidentally able to work around the issue using some javascript on the expand/collapse column click event:
onclick="$find('G1_ctl00')._toggleExpand(this.parentNode, event);FixIE7ButtonHide(this);"

function FixIE7ButtonHide(inDiv) {
    var nRow = inDiv.parentNode.parentNode.parentNode.nextSibling;
    nRow.children[1].children[0].children[0].style.display = ('none' == nRow.style.display ? 'none' : ''); 
}
Tags
Button
Asked by
Adam
Top achievements
Rank 1
Answers by
Pero
Telerik team
Adam
Top achievements
Rank 1
Share this question
or