Open new window fromn ASP.Net and pass parameters

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Vaughn Haybittle

    Open new window fromn ASP.Net and pass parameters

    Hi,

    I have an asp.net page with three Drow-Down-Lists and a Gridview server
    control. I want to open a new window from this page and open another .aspx
    page in this window. I also want to be able to pass the 'SelectedValue"
    property of the gridview and Drop-Down-Lists into the new window so that I
    can use them to further process data.

    I know that there are a few options to do this. What are they, and which is
    considere dto be best practice.

    Many thanks,

    Regards,

    Vaughn


  • Laurent Bugnion

    #2
    Re: Open new window fromn ASP.Net and pass parameters

    Hi,

    Vaughn Haybittle wrote:
    Hi,
    >
    I have an asp.net page with three Drow-Down-Lists and a Gridview server
    control. I want to open a new window from this page and open another .aspx
    page in this window. I also want to be able to pass the 'SelectedValue"
    property of the gridview and Drop-Down-Lists into the new window so that I
    can use them to further process data.
    >
    I know that there are a few options to do this. What are they, and which is
    considere dto be best practice.
    >
    Many thanks,
    >
    Regards,
    >
    Vaughn
    You could post the values (using a POSTed form) with the target set to
    the new window's name. In that case, the server will process the data,
    and the result will be displayed in the new window. Alternatively, you
    can open the new window with a GET (i.e. a URL with a query string).

    To open the new window, you will typically use JavaScript's window.open,
    but you must know that more and more developers frown upon pop-ups (and
    some pop-up blockers will prevent them from being displayed).

    A high-end alternative could be to use inline DIVs with absolute
    positioning, and using AJAX to trigger the server and get the response
    without having to reload the page.

    HTH,
    Laurent
    --
    Laurent Bugnion [MVP ASP.NET]
    Software engineering: http://www.galasoft-LB.ch
    PhotoAlbum: http://www.galasoft-LB.ch/pictures
    Support children in Calcutta: http://www.calcutta-espoir.ch

    Comment

    Working...