Problem with embedded RadListView

2 posts, 0 answers
  1. Lee
    Lee avatar
    5 posts
    Member since:
    Jul 2011

    Posted 01 Jul 2011 Link to this post

    We have the following code. At first we attempted to use a RadDataPager for the paging but the paging wasnt working. So i added asp buttons to see what is occuring the following error is returned:

    Microsoft JScript runtime error: Sys.ArgumentException: Value must not be null for Controls and Behaviors.
    Parameter name: element

    I think the problem is that this RadListView is embedded within another RadListView (and some other server controls) further up the page. How can we get an embedded RadListView like this to page correctly?

    Code is below.

    <asp:Panel ID="pnlMultiImagePreview" runat="server" Visible="false">
                            <asp:UpdatePanel ID="upMultiImagePreview" runat="server">
                                    <telerik:RadListView ID="rlvMultiImagePreview" runat="server" DataKeyNames="PreviewImage" AllowPaging="true" ItemPlaceholderID="ImagesContainer" PageSize="1" >
                                            <asp:Panel ID="pnlMultiImagePage" runat="server">
                                                <asp:Image ID="imgMultiThumb" runat="server" ImageUrl='<%#Eval("PreviewImage")%>' CssClass="previewImage" />
                                       <!-- Set the id of the wrapping container to match the CLIENT ID of the RadListView control to display the ajax loading panel           In case the listview is embedded in another server control, you will need to append the id of that server control -->
                                        <fieldset id="rlvMultiImagePreview">
                                        <asp:PlaceHolder ID="ImagesContainer" runat="server" />
                                            <div style="padding-left: 20%;">
                                             <asp:Button runat="server" ID="btnFirst" CommandName="Page" CommandArgument="First"
                            Text="First" Enabled="<%#Container.CurrentPageIndex > 0 %>" />
                        <asp:Button runat="server" ID="btnPrev" CommandName="Page" CommandArgument="Prev"
                            Text="Prev" Enabled="<%#Container.CurrentPageIndex > 0 %>" />
        <span style="vertical-align: top; position: relative; top: 4px">Page <%#Container.CurrentPageIndex + 1 %> of <%#Container.PageCount%> </span>
                        <asp:Button runat="server" ID="btnNext" CommandName="Page" CommandArgument="Next"
                            Text="Next" Enabled="<%#Container.CurrentPageIndex + 1 < Container.PageCount %>" />
                        <asp:Button runat="server" ID="btnLast" CommandName="Page" CommandArgument="Last"
                            Text="Last" Enabled="<%#Container.CurrentPageIndex + 1 < Container.PageCount %>" />
                                                <br />
                                            <div id="itemPlaceHolder" runat="server">


  2. Genti
    Genti avatar
    107 posts

    Posted 06 Jul 2011 Link to this post

    Hi Lee,

    I suspect the issue that you are having is not coming because of multiple nested list views.
    I see that you have an update panel that wraps the RadListView. Do you have any other panels in the page or in the page that has the current control? If so try removing them and check whether the issue persists.

    I am also attaching a simple project that illustrates nesting ListViews.

    Hope this helps.

    the Telerik team

    Register for the Q2 2011 What's New Webinar Week. Mark your calendar for the week starting July 18th and book your seat for a walk through of all the exciting stuff we will ship with the new release!

Back to Top