<
telerik:GridBoundColumn DataField="EmailAddress" AllowFiltering="true" HeaderText="Email Address" FilterControlWidth="150px"
AutoPostBackOnFilter="true" CurrentFilterFunction="Contains" ShowFilterIcon="false" UniqueName="EmailAddress"/>
Hello,
I have a RadWindow defined as the following:
<telerik:RadWindow ID="radWindow360Value" runat="server"
SkinID="Default" Behaviors="Close" NavigateUrl="~/360Value.aspx"
OpenerElementID="btnDetailedCostCalc"
OnClientClose="clientClose360Value"
OnClientShow="clientShow360Value"
Left="5px" Width="800px" Height="700px">
</telerik:RadWindow>
The 360Value.aspx page is the following:
<body id="bdy36Value" runat="server">
<form id="frm360Value" runat="server">
<div id="div360Viewer" runat="server">
<iframe id="ifm360Value" runat="server" frameborder="0" scrolling="auto" src="BlankPage.aspx" width="100%" height="100%"></iframe>
</div>
<br />
<asp:Button ID="btnDone" runat="server" UseSubmitBehavior="false" Text="Done" OnClientClick="return close360Value();" />
</form>
</body>
When the window is popped up via the following:
<input type="button" id="btnDetailedCostCalc" class="btn" runat="server" onclick="Show360ValueWindow();" value="Launch Detailed Cost Calculator" />
function Show360ValueWindow() {
var oWnd = $find(s360ValueRadWindowClientID);
oWnd.SetSize(document.documentElement.clientWidth - 20, document.documentElement.clientHeight - 15);
oWnd.show();
oWnd.MoveTo(10, document.documentElement.scrollTop + 10);
}
I get an "Invalid Argument" on line 54 which is in the resize function of the telerik controls xv2scripts.js file. Specifically, this is line 54:
contentObj.style.height = (getWindowHeight() - nonContentHeight) + "px";
The current values of those items are:
contentObj.style.height = ""
getWindowHeight() = 150
nonContentHeight = 177
What can I do to have this not throw the error. I am working in IE8 and it happens in both normal and compatibility mode.
Thanks,
Kevin
| <%@ Control Language="C#" AutoEventWireup="true" CodeBehind="OUTreeview.ascx.cs" |
| Inherits="OUTreeview" %> |
| <%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %> |
| <div> |
| <telerik:RadAjaxManagerProxy ID="RadAjaxManagerProxy1" runat="server"> |
| <AjaxSettings> |
| <telerik:AjaxSetting AjaxControlID="rtvDSMOU" EventName="rtvDSMOU_NodeExpand"> |
| <UpdatedControls> |
| <telerik:AjaxUpdatedControl ControlID="rtvDSMOU" LoadingPanelID="RadAjaxLoadingPanel1" /> |
| </UpdatedControls> |
| </telerik:AjaxSetting> |
| </AjaxSettings> |
| </telerik:RadAjaxManagerProxy> |
| <telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" Height="75px" |
| Width="75px"> |
| <img alt="Loading..." src='<%= RadAjaxLoadingPanel.GetWebResourceUrl(Page, "Telerik.Web.UI.Skins.Default.Ajax.loading.gif") %>' |
| style="border: 0px;" /> |
| </telerik:RadAjaxLoadingPanel> |
| <telerik:RadTreeView ID="rtvDSMOU" runat="server" OnNodeExpand="rtvDSMOU_NodeExpand" |
| BorderStyle="None" BorderWidth="0px" OnNodeCollapse="rtvDSMOU_NodeCollapse" OnNodeClick="rtvDSMOU_NodeClick" |
| ShowLineImages="False"> |
| <CollapseAnimation Duration="100" Type="OutQuad" /> |
| <ExpandAnimation Duration="100" Type="InQuad" /> |
| </telerik:RadTreeView> |
| </div> |
I have a client-bind Grid which has GridTemplateColumn to show a checkbox.
<
telerik:RadGrid ID="RadGrid1" EnableViewState="False" Skin="WebBlue" runat="server"
AllowPaging="True" AllowSorting="True" AllowFilteringByColumn="True"
AutoGenerateColumns="False" Width="100%"
EnableAJAXLoadingTemplate="True" EnableAJAX="True" GridLines="None" >
<MasterTableView AllowNaturalSort="false" AccessKey="x"
AllowFilteringByColumn="True"
ClientDataKeyNames="IsReviewed, ID, Message, Category" CellSpacing="-1" >
<Columns>
<telerik:GridTemplateColumn HeaderText="Review" >
<ItemTemplate>
<asp:CheckBox ID="CheckBox" runat="server" />
</ItemTemplate>
</telerik:GridTemplateColumn>
<telerik:GridDateTimeColumn DataField="TimeStamp" HeaderText="Date and Time" DataFormatString="{0:M/d/yyyy h:mm tt}" UniqueName="Time"/>
</Columns>
</MasterTableView>
<ClientSettings AllowKeyboardNavigation="True">
<ClientEvents OnRowDataBound="RowDataBound" ></ClientEvents>
<DataBinding SelectMethod="GetDataAndCount" Location="~/service/Service.svc" SortParameterType="Linq" FilterParameterType="Linq" >
</DataBinding>
</ClientSettings>
Here is the script to handle data bind on check box:
function RowDataBound(sender, args) {
var radTextBox1 = args.get_item().findElement("CheckBox");
radTextBox1.checked = args.get_dataItem()["IsReviewed"];
}
In normal situation, everything is fine. However, when I change the page size, the client side didn't create the check box for the increased new rows. The script is failed due to can't find the radTextBox1. I did some trace, the data is succeeded binding, other columns are fine, only this GridTemplateColumn has issue to create.
How can I reslove this issue?
| <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server"> |
| <AjaxSettings> |
| <telerik:AjaxSetting AjaxControlID="DropDownList"> |
| <UpdatedControls> |
| <telerik:AjaxUpdatedControl ControlID="Literal" /> |
| <telerik:AjaxUpdatedControl ControlID="Repeater " /> |
| </UpdatedControls> |
| </telerik:AjaxSetting> |
| </AjaxSettings> |
| </telerik:RadAjaxManager> |
| <div> |
| <ul> |
| <asp:Literal id="Literal" runat="server">This list is empty.</asp:Literal> |
| <asp:Repeater ID="Repeater" runat="server"> |
| <ItemTemplate> |
| <li> |
| <%#Container.DataItem("Item")%> |
| </li> |
| </ItemTemplate> |
| </asp:Repeater> |
| </ul> |
| <br /> |
| <div> |
| <asp:DropDownList ID="DropDownList" runat="server" AutoPostBack="true"> |
| <asp:ListItem Text="Item One" Value="1" /> |
| <asp:ListItem Text="Item Two" Value="2" /> |
| <asp:ListItem Text="Item Three" Value="3" /> |
| <asp:ListItem Text="Item Four" Value="4" /> |
| <asp:ListItem Text="Item Five" Value="5" /> |
| </asp:DropDownList> |
| </div> |
| </div> |
| Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load |
| If Not IsPostBack Then |
| LoadList() |
| End If |
| End Sub |
| Sub LoadList() |
| Repeater.DataSource = "MyDataSource" |
| Repeater.DataBind() |
| If Repeater.Items.Count > 0 Then |
| Repeater.Visible = True |
| Literal.Visible = False |
| Else |
| Repeater.Visible = False |
| Literal.Visible = True |
| End If |
| End Sub |
| Protected Sub DropDownList_SelectedIndexChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles DropDownList.SelectedIndexChanged |
| 'Add the Item here |
| LoadList() |
| End Sub |
| <asp:UpdatePanel ID="UpdatePanel1" runat="server"> |
| <ContentTemplate> |
| <div> |
| <ul> |
| <li id="Literal" runat="server">This list is empty.</li> |
| <asp:Repeater ID="Repeater" runat="server"> |
| <ItemTemplate> |
| <li> |
| <%#Container.DataItem("BusinessName")%> |
| </li> |
| </ItemTemplate> |
| </asp:Repeater> |
| </ul> |
| <br /> |
| <div> |
| <asp:DropDownList ID="DropDownList" runat="server" AutoPostBack="true"> |
| <asp:ListItem Text="Item One" Value="17" /> |
| <asp:ListItem Text="Item Two" Value="19" /> |
| <asp:ListItem Text="Item Three" Value="20" /> |
| <asp:ListItem Text="Item Four" Value="21" /> |
| <asp:ListItem Text="Item Five" Value="22" /> |
| </asp:DropDownList> |
| </div> |
| </div> |
| </ContentTemplate> |
| </asp:UpdatePanel> |