Open popup aspx page

G

Guest

Hi,
I have a usercontrol with a button. In the button's click event I have to open an instance of an aspx page, passing some values to some public variables of the page.
How can I call the instance of the right page?

The code is the follow:

//this is the webpage
LookUpWebForm LUWF = new LookUpWebForm

//these are the variables valued
LUWF.TabellaDB = m_DBTable;
LUWF.IDLookUp = ID;
LUWF.PageSize = PageSize;

i need to open the LookUpWebForm's aspx file in this way: BtnLookUp.Attributes.Add("onclick", "window.open('AreaITControls/LookUpWebForm.aspx');")

but, in the LookUpWebForm's PageLoad event the variables are not setted.

Thank you
Alessandro Rossi
 
A

Anatoly

Pass parameters to page by QueryString collection like:
window.open("MyPage.aspx?param1=value1&param2=value2...)

in this page you can access this params by:

string param1 = Request.QueryString["param1"];
....
HTH


Alessandro Rossi said:
Hi,
I have a usercontrol with a button. In the button's click event I have to
open an instance of an aspx page, passing some values to some public
variables of the page.
 
G

Guest

I wouldn't pass parameters in a quesrystring because I've long parameters, and so, I was asking if there is a way to create an instance of an aspx page, and open via javascript this instance with public variables valued..

Thank yo
Alessandro Ross

----- Anatoly wrote: ----

Pass parameters to page by QueryString collection like
window.open("MyPage.aspx?param1=value1&param2=value2...

in this page you can access this params by

string param1 = Request.QueryString["param1"]
...
HT


Alessandro Rossi said:
Hi
I have a usercontrol with a button. In the button's click event I have t
open an instance of an aspx page, passing some values to some publi
variables of the page
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,767
Messages
2,569,572
Members
45,045
Latest member
DRCM

Latest Threads

Top