Page view counter

I have problem in paginate

Last post 09-01-2008 7:25 AM by irtizaur. 1 replies.

Sort Posts:

  • I have problem in paginate

    08-28-2008, 7:09 AM
    • Loading...
    • nwmganesh
    • Joined on 08-25-2008, 8:48 AM
    • Posts 2

    Hi,

    In my mobile form i put one textbox, command button, object list.
    Suppose i give form1 pagination = true. page per item = 10,
    The item are displayed 10 per page. But the controls textbox,
    command button are not visible when i click next button.
    I dont know why the controls textbox and command button are not visible when click next.
    Is anybody faced this problem? plz ans. thnx...

    with regards ganeshConfused

  • Re: I have problem in paginate

    09-01-2008, 7:25 AM
    Answer
    • Loading...
    • irtizaur
    • Joined on 04-21-2007, 3:09 PM
    • Posts 62

    it's because your next command inside objectlist control suppose to paginate the objectlist contains only not the forms properties(here, textbox and command). but if you want to paginate those with your objectlist control pagination then you have to include them inside objectlist container and use custom ojectlist data binding. here is an example

     

    1    <%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>
    2    <%@ Register TagPrefix="mobile" Namespace="System.Web.UI.MobileControls" Assembly="System.Web.Mobile" %>
    3    
    4    <html xmlns="http://www.w3.org/1999/xhtml" >
    5    <body>
    6        <mobile:Form id="Form1" runat="server" Paginate="true">
    7            <mobile:ObjectList ID="ObjectList1" Runat="server" CommandStyle-StyleReference="subcommand"
    8                LabelStyle-StyleReference="title" ItemsPerPage="10">
    9                <DeviceSpecific Runat="server">
    10               <Choice>
    11               <HeaderTemplate>
    12                   <mobile:TextBox ID="TextBox1" runat="server"></mobile:TextBox>
    13                   <mobile:Command ID="Command1" runat="server">Command</mobile:Command>
    14               </HeaderTemplate>
    15               <ItemTemplate><%# Eval("FirstName") %> <%# Eval("LastName") %></ItemTemplate>
    16               </Choice>                
    17               </DeviceSpecific>
    18           </mobile:ObjectList>
    19       </mobile:Form>
    20   </body>
    21   </html>
    22   
    

      

    but remember you have to handle the text box and command control according to the objectlist container's property. :)

    hope that helps

    Irtizaur Rahman

    Please: Don't forget to click "Mark as Answer" on the post that helped you. That way future readers will know which post solved your issue.
Page 1 of 1 (2 items)
Microsoft Communities