Cross page postback

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • jazzart@mail.com

    #1

    Cross page postback

    Hi all,

    I have been trying to implement cross page postback with a Repeater,
    to no avail..

    I have a Repeater on search.aspx which lists items from a database. In
    each item template is a linkbutton that performs a cross page postback
    to details.aspx.

    On details.aspx I need to find the item in which the linkbutton was
    selected. Is there any way at all to achieve this? Either by passing a
    value (like the id of the data item), or by using FindControl to find
    a textbox in that item.

    I have searched high and low on google and various forums for a whole
    day and have found nothing on this. All the examples I've found on
    cross page postback reference static controls that are hard coded but
    what about data bound items?

    Any help would be greatly greatly appreciated.

    Cheers,
    Karen

  • bruce barker

    #2
    Re: Cross page postback


    I see no reason to do a postback at all. use a hyperlink with
    display.aspx?id =<itemidand in display.aspx use
    Request.QuerySt ring["id"] to get the value. then no javascript is
    required, and bookmarks work.

    -- bruce (sqlwork.com)




    jazzart@mail.co m wrote:
    Hi all,
    >
    I have been trying to implement cross page postback with a Repeater,
    to no avail..
    >
    I have a Repeater on search.aspx which lists items from a database. In
    each item template is a linkbutton that performs a cross page postback
    to details.aspx.
    >
    On details.aspx I need to find the item in which the linkbutton was
    selected. Is there any way at all to achieve this? Either by passing a
    value (like the id of the data item), or by using FindControl to find
    a textbox in that item.
    >
    I have searched high and low on google and various forums for a whole
    day and have found nothing on this. All the examples I've found on
    cross page postback reference static controls that are hard coded but
    what about data bound items?
    >
    Any help would be greatly greatly appreciated.
    >
    Cheers,
    Karen
    >

    Comment

    • jazzart@mail.com

      #3
      Re: Cross page postback

      The reason I need to do a cross page postback is because the target
      page needs to know information from the previous page in order to do
      things like paging (going to the next and previous result in the paged
      data table) and also to remember the search results to navigate back
      to.

      Can you suggest an alternative way of maintaining this information?
      Should I be storing all of this in the session object instead?


      On 13 Apr, 16:29, bruce barker <nos...@nospam. comwrote:
      I see no reason to do apostbackat all. use a hyperlink with
      display.aspx?id =<itemidand in display.aspx use
      Request.QuerySt ring["id"] to get the value. then no javascript is
      required, and bookmarks work.
      >
      -- bruce (sqlwork.com)
      >
      jazz...@mail.co m wrote:
      Hi all,
      >
      I have been trying to implementcrossp agepostbackwith a Repeater,
      to no avail..
      >
      I have a Repeater on search.aspx which lists items from a database. In
      each item template is a linkbutton that performs acrosspagepostb ack
      to details.aspx.
      >
      On details.aspx I need to find the item in which the linkbutton was
      selected. Is there any way at all to achieve this? Either by passing a
      value (like the id of the data item), or by using FindControl to find
      a textbox in that item.
      >
      I have searched high and low on google and various forums for a whole
      day and have found nothing on this. All the examples I've found on
      crosspagepostba ckreference static controls that are hard coded but
      what about data bound items?
      >
      Any help would be greatly greatly appreciated.
      >
      Cheers,
      Karen

      Comment

      Working...