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

Telerik Ajax problem

4 Answers 52 Views
Ajax
This is a migrated thread and some comments may be shown as answers.
Thien
Top achievements
Rank 1
Thien asked on 27 Oct 2010, 02:11 PM
Hello,
In a page, I have one radgrid and one panel for edit form
    <telerik:RadGrid ID="listCompany" runat="server"   AllowMultiRowSelection="false" PagerStyle-AlwaysVisible="true"
        OnItemCreated="RadGrid1_ItemCreated">
        <MasterTableView AutoGenerateColumns="false" DataKeyNames="Id">
            <Columns>
                  ........
            </Columns>
        </MasterTableView>
        <ClientSettings EnableRowHoverStyle="true" />
    </telerik:RadGrid>
 
<asp:Panel ID="editForm" runat="server">
    .......
</asp:Panel>

And my Ajax Setting
protected void Page_Load(object sender, EventArgs e)
{
    RadAjaxManager radAjaxManager = Page.Master.FindControl("radAjaxManager") as RadAjaxManager;
    RadAjaxLoadingPanel radAjaxLoaingPanel = Page.Master.FindControl("radAjaxLoadingPanel") as RadAjaxLoadingPanel;
    radAjaxManager.AjaxSettings.AddAjaxSetting(listCompany, listCompany, radAjaxLoadingPanel);
}
protected void RadGrid1_ItemCreated(object sender, Telerik.Web.UI.GridItemEventArgs e)
{
if (e.Item is GridDataItem)
{
   RadAjaxManager radAjaxManager = Page.Master.FindControl("radAjaxManager") as RadAjaxManager;
   RadAjaxLoadingPanel radAjaxLoaingPanel = Page.Master.FindControl("radAjaxLoadingPanel") as RadAjaxLoadingPanel;
   LinkButton editLink = (LinkButton)e.Item.FindControl("LinkEdit");
   radAjaxManager.AjaxSettings.AddAjaxSetting(editLink , editForm, radAjaxLoadingPanel);
 }


If I click on one row in the grid, the edit form show, everything ok. But if I do sorting then click one row in the grid. The overlay of edit form can't be hidden.

Can anybody help me!
Many many thanks

4 Answers, 1 is accepted

Sort by
0
Cori
Top achievements
Rank 2
answered on 27 Oct 2010, 03:03 PM
Hello Thien,

If you add you RadGrid to the RadAjaxMager collection, there is no need to add the links contained in the RadGrid, since they are automatically ajaxed as well.

I hope that helps.
0
Thien
Top achievements
Rank 1
answered on 27 Oct 2010, 03:16 PM
Thank Cori ,
But when clicking edit button on each row, I want only the edit form get updated.
0
Marin
Telerik team
answered on 28 Oct 2010, 07:43 AM
Hello Thien,

We made some tests but could not reproduce exactly the same problem. From the code snippet It seems that there is some problem with the ajaxifying of the controls in your grid. Especially the ajaxifying of the grid itself in page load, you may try temporary turning it off or moving it to Page_PreRender event. Also if the problem persists can you sends us a sample application that reproduces it so we can debug it on our end.

Regards,
Marin
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Thien
Top achievements
Rank 1
answered on 28 Oct 2010, 06:31 PM
I just found something. My website use .net 4.0 and deployed in IIS 7.5 integrated mode. The problem doesn't appear when running in build-in server
Tags
Ajax
Asked by
Thien
Top achievements
Rank 1
Answers by
Cori
Top achievements
Rank 2
Thien
Top achievements
Rank 1
Marin
Telerik team
Share this question
or