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

RadAjaxManager causing "Object doesn't support this property or method" error

1 Answer 64 Views
Ajax
This is a migrated thread and some comments may be shown as answers.
bdk0172
Top achievements
Rank 1
bdk0172 asked on 17 Nov 2009, 06:32 PM
I have a RadAjaxManager within my MasterPage directly below the form tag:

 

<form id="form1" runat="server">

 

 

<telerik:RadAjaxManager ID="RadAjaxManager" runat="server"></telerik:RadAjaxManager>

 


I have a usercontrol where I have a RadAjaxLoadingPanel along with a RadGrid:

<

 

telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" Height="75px"

 

 

Width="75px" Transparency="100">

 

 

<label runat="server">Loading...</label>

 

 

<br />

 

 

<img style="border: 0; margin-top: 150px;" alt="Loading..." src="../img/Vista.gif" />

 

</

 

telerik:RadAjaxLoadingPanel>

 

<

 

telerik:RadGrid ID="grdTicket" Skin="Office2007" Width="100%" AllowSorting="True"

 

 

AllowPaging="True" PageSize="50" runat="server" AllowMultiRowSelection="true" OnItemDataBound="grdTicket_ItemDataBound"

 

 

OnNeedDataSource="grdTicket_NeedDataSource" OnColumnCreated="grdTicket_ColumnCreated" OnItemCreated="grdTicket_ItemCreated">

 

 

<MasterTableView Width="100%" NoMasterRecordsText="No records to display" TableLayout="Fixed" HeaderStyle-Wrap="true">

 

 

<Columns>

 

 

<telerik:GridClientSelectColumn Reorderable="False" UniqueName="ClientSelectColumn">

 

 

<HeaderStyle Width="25px"></HeaderStyle>

 

 

</telerik:GridClientSelectColumn>

 

 

 

<telerik:GridTemplateColumn HeaderText="WTB" DataField="wtbdt" UniqueName="WTBIndicator" Groupable="false" SortExpression="wtbdt">

 

 

<HeaderStyle Width="35px" />

 

 

<ItemStyle HorizontalAlign="Center" />

 

 

<ItemTemplate>

 

 

<asp:Image ID="WTBIndicator" runat="server">

 

 

</asp:Image>

 

 

</ItemTemplate>

 

 

</telerik:GridTemplateColumn>

 

 

<telerik:GridBoundColumn DataField="wtbindicator" SortExpression="wtbindicator" Visible="false"></telerik:GridBoundColumn>

 

 

</Columns>

 

 

</MasterTableView>

 

 

<PagerStyle Mode="NumericPages" />

 

 

<ClientSettings>

 

 

<Selecting AllowRowSelect="True"></Selecting>

 

 

</ClientSettings>

 

 

<PagerStyle Mode="NumericPages" />

 

</

 

telerik:RadGrid>

 


In the usercontrol Page_Load, I'm getting the RadAjaxManager from the MasterPage and then setting the AjaxSettings:

RadAjaxManager

 

ram = (RadAjaxManager)this.Page.Master.FindControl("RadAjaxManager");

 

ram.AjaxSettings.AddAjaxSetting(grdTicket, grdTicket);

ram.DefaultLoadingPanelID =

"RadAjaxLoadingPanel1";

 


When the usercontrol is loaded into the page and when I retrieve records for my grid, everything is fine.  The problem occurs when I click on a grid header to do a sort.  I get "Microsoft JScript runtime error: Object doesn't support this property or method" in the italicized code below.

Sys.UI.Control =

function Sys$UI$Control(element) {

 

 

/// <summary locid="M:J#Sys.UI.Control.#ctor" />

 

 

/// <param name="element" domElement="true"></param>

 

 

var e = Function._validateParams(arguments, [

 

{name:

"element", domElement: true}

 

]);

 

if (e) throw e;

 

 

if (typeof(element.control) != 'undefined') throw Error.invalidOperation(Sys.Res.controlAlreadyDefined);

 

Sys.UI.Control.initializeBase(

this);

 

 

this._element = element;

 

element.control =

this;

 

1 Answer, 1 is accepted

Sort by
0
Martin
Telerik team
answered on 20 Nov 2009, 01:33 PM
Hello Brian,

I have build a small sample project based on your scenario that runs as expected on my end. Please give it a try and let me know how it goes.

Best regards,
Martin
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Tags
Ajax
Asked by
bdk0172
Top achievements
Rank 1
Answers by
Martin
Telerik team
Share this question
or