Popups

S

Steven Spits

Ann Marinas said:
is there any possibility that i could create a pop-up in asp.net?

Sure. It's not because you're using a server-side scripting technology that
you can't use client-side scripting.

You can use window.open() freely in your document.

Steven

- - -
 
A

Ann Marinas

hi all!

is there any possibility that i could create a pop-up in asp.net?

thanks a million!

-A
 
G

Gibs

you can use showModalDialog to open a popup window.

StringBuilder strScript = new StringBuilder();
strScript.Append("javascript:window.showModalDialog");
strScript.Append("('openingpage.aspx");
strScript.Append("','','dialogHeight:200px;dialogWidth:300px');");

and you can add this to your button using this.

button.Attributes.Add("OnClick",strScript.ToString());

HTH
 
A

Ann Marinas

Hi, Steven!

Thank you for answering my question. I really do appreciate it!

How can I use the 'window.open()' method?

-A
 
P

Peter Rilling

Read the MSDN documentation.

Ann Marinas said:
Hi, Steven!

Thank you for answering my question. I really do appreciate it!

How can I use the 'window.open()' method?

-A
 
M

matt

You should be aware that showModalDialog will only work in IE and is modal
(will take focus away from the window that opens the modal dialog until you
close it....)

window.open may be more what you are looking for, in which case you can use
a similar approach but replace the window.showModalDialog with the
window.open call. (Check MSDN for more detail on wither of these methods
and the parameters to pass to them).

Matt
 

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,769
Messages
2,569,582
Members
45,057
Latest member
KetoBeezACVGummies

Latest Threads

Top