Sauron
Sauron

Reputation: 16923

Open and Close Popup windows without Javascript in ASP.NET

How can I Open and Close Popup windows without Javascript in ASP.NET?

Upvotes: 0

Views: 2554

Answers (3)

Olivier Payen
Olivier Payen

Reputation: 15268

You can't.

Opening and closing popups implies javascript code execution on the client side.

You could eventually create an ASP.Net panel that looks like a popup and set it visible/invisible during the postback but it won't behave like a 'real' popup.

Upvotes: 1

Matrich
Matrich

Reputation: 183

Unless otherwise but I conquer with @Olivier that you can't do that without using Javascript. Even with the solution given by @Avi, you are still using Javascript though it is kinda abstracted from you.

Maybe, you could explain why you don't want to use javascript because even without the AjaxControl, it is kinda pretty easy to open and specify other properties of pop up windows.

Upvotes: 0

Greg B
Greg B

Reputation: 14898

What do you mean "Popup windows".

JavaScript allows you to manipulate the properties of a window object allowing you to remove the status bar, address bar, set the size and position of the new window and other things.

The only other way (short of using VB script :) is to have links with target set to _blank. But then you can't customise the new window.

Upvotes: 4

Related Questions