I am unable to get the ClientID fo the Rad Combo box control ($find("<%= rComboResultsPerPage.ClientID %>") which is present in the Pager Template of the Rad Grid. Is there any way to fetch it? I have pasted my working code below.
<script type="text/javascript">
function pageLoad(sender, args) {
gridCount = parseInt(document.getElementById("<%= hidGridCount.ClientID %>").value);
if (gridCount > 0)
var tableView = $find("<%= radgridEventSearch.ClientID %>").get_masterTableView();
var savedValue = $get("RadComboBox1Value").value;
var combo = $find("<%= rComboResultsPerPage.ClientID %>");
if (savedValue != "" && combo.findItemByValue(savedValue)) {
combo.findItemByValue(savedValue).select();
}
}
</script>
<telerik:RadGrid ID="radgridEventSearch" runat="server" GridLines="None" AllowPaging="True"
EnableViewState="false" AllowCustomPaging="true" VirtualItemCount="1000000" AllowSorting="True"
AutoGenerateColumns="false" Skin="Vista" OnSortCommand="radgridEventSearch_SortCommand"
OnNeedDataSource="radgridEventSearch_NeedDataSource" PageSize="25">
<MasterTableView AllowCustomSorting="true" AllowNaturalSort="false">
<PagerTemplate>
<!-- There is some additional code goes here -->
<telerik:RadComboBox ID="rComboResultsPerPage" DataSource="<%# FillResultsPerPageDropDownList() %>"
SelectedValue='<%# (int)DataBinder.Eval(Container, "Paging.PageSize") %>' runat="server"
OnClientSelectedIndexChanged="rComboResultsPerPage_SelectedIndexChanged" Width="50px">
</telerik:RadComboBox>
<!-- There is some additional code goes here -->
</PagerTemplate>
<PagerStyle PageButtonCount="10" Position="TopAndBottom" AlwaysVisible="true" />
<!-- There is some additional code goes here -->
<asp:HiddenField ID="hidGridCount" Value="0" runat="server" />
<input type="hidden" id="RadComboBox1Value" value="" />
Thanks
Rama Rao