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

PopupControlExtender JScript errors

6 Answers 94 Views
Grid
This is a migrated thread and some comments may be shown as answers.
david
Top achievements
Rank 1
david asked on 16 Jun 2008, 06:04 PM
I am trying to use a RadGrid with paging enabled inside a PopupControlExtender, but it is not working properly.

The grid is displayed fine the first time, but then when I click on the next page button I get a JScript error: "Microsoft JScript runtime error: 'this._postBackSettings.async' is null or not an object" which seems to possibly be caused by an unwanted post back?

The MS GridView works as expected in this setup, paging through the data keeping the popup control open, not causing a full postback.

The setup is fairly simple:

    <form id="form1" runat="server">
<cc1:ToolkitScriptManager ID="ToolkitScriptManager1" runat="server">
</cc1:ToolkitScriptManager>
   
    <div>
        <asp:ObjectDataSource ID="ObjectDataSource1" runat="server"></asp:ObjectDataSource>
          
        <asp:TextBox ID="TextBox1" runat="server"></asp:TextBox>

        <asp:UpdatePanel ID="UpdatePanel1" runat="server" UpdateMode="Conditional">
            <ContentTemplate>
                <telerik:RadGrid ID="RadGrid1" runat="server" AllowPaging="True" AllowSorting="True" GridLines="None" onneeddatasource="RadGrid1_NeedDataSource" PageSize="5" >
                </telerik:RadGrid>
            </ContentTemplate>
        </asp:UpdatePanel>  
       
        <cc1:PopupControlExtender ID="PopupControlExtender1" runat="server" TargetControlID="TextBox1" PopupControlID="RadGrid1">
        </cc1:PopupControlExtender>
       
    </div>
    </form> Thanks.

6 Answers, 1 is accepted

Sort by
0
david
Top achievements
Rank 1
answered on 16 Jun 2008, 06:48 PM
Actually, just a little more info:

If you continue after the first time, it works properly from then on in.

It just seems to me that the first time you click on next it submits the form for some reason. Any way to disable this?
0
david
Top achievements
Rank 1
answered on 16 Jun 2008, 07:03 PM
More interestingness:

If you filter the grid once before you change the page it does not have the error.

Also, I actually have several different grids on the one page, once one of them has had the error the others DO NOT have it.


0
Sebastian
Telerik team
answered on 19 Jun 2008, 11:17 AM
Hi David,

Your observations are indeed strange and unfortunately from the description so far I am not able to determine the exact reason for the error you receive for one of your grid instance.

To progress in our investigation, I suggest you isolate a working subset of your project and send it enclosed to a formal support ticket. I will examine your complete code logic in detail and will get back to you with my findings.

Best regards,
Stephen
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
david
Top achievements
Rank 1
answered on 19 Jun 2008, 07:55 PM
Your ticket ID is : 145316
0
Sebastian
Telerik team
answered on 23 Jun 2008, 12:13 PM

Hi David,

Thank you for the sample application.

After testing the project locally I discovered that the issue is related to the next/previous image buttons rendered in the RadGrid pager. Placing even a default asp ImageButton inside the PopupControlExtender produces the same exception when clicking it. I suppose this is a bug in the present version of the Ajax Toolkit Popup Extender and you may consider reporting it to Microsoft to be fixed for its future versions.

At the present moment the workaround I can suggest is to use pure numeric pager in the grid with hyperlinks (see the updated version of the project) or define a pager template holding LinkButtons/Buttons for next/previous page navigation.

Kind regards,

Stephen

the Telerik team


Instantly find answers to your questions at the new Telerik Support Center
0
John Thomas
Top achievements
Rank 1
answered on 27 Aug 2008, 09:13 PM
I was getting the same error on a page that contained both a RadScriptManager and a Microsoft Report Viewer control.  Clicking "View Report" caused this error.

After reading this entry
http://aspnetresources.com/blog/cancelling_event_bubble_interferes_with_ms_ajax.aspx

I discovered that setting the EnablePartialRendering to false on the script manager works:

<telerik:RadScriptManager ID="ScriptManager1" runat="server" EnableTheming="True"

EnablePartialRendering="false" OutputCompression="AutoDetect">


Tags
Grid
Asked by
david
Top achievements
Rank 1
Answers by
david
Top achievements
Rank 1
Sebastian
Telerik team
John Thomas
Top achievements
Rank 1
Share this question
or