Open new window fromn ASP.Net and pass parameters

  • Thread starter Thread starter Vaughn Haybittle
  • Start date Start date
V

Vaughn Haybittle

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
 
Hi,

Vaughn said:
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
 
Back
Top