473,573 Members | 2,910 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Popup Window generated from Server Side

I would like to generate non-modal popup windows from
ASP.Net code-behind. I have tried using Client Side
scripting like "function Test(){
window.open('te st.htm',_blank,
'height=200,wid th=400,status=n o,toolbar=no,
menubar=no,loca tion=no resizable=no
scrollable=no') ;
but I can't seem to invoke the client side script from
within a Server Side Form. I know I can use the context
with to Response.redire ct or Server.transfer to return a
different page, but can't figure how generate a pop-up
window for an 'About' page or a "Contacts" page.

Jul 21 '05 #1
12 12407

"HarveyB" <ha*****@compas s-soft.com> wrote in message
news:01******** *************** *****@phx.gbl.. .
I would like to generate non-modal popup windows from
ASP.Net code-behind.


How about using Response.Write in your server side code:

Response.Write( "<script language='javas cript'>window.o pen(....)</script>");

---
Steven Wood
Jul 21 '05 #2
-----Original Message-----

"HarveyB" <ha*****@compas s-soft.com> wrote in message
news:01******* *************** ******@phx.gbl. ..
I would like to generate non-modal popup windows from
ASP.Net code-behind.
How about using Response.Write in your server side code:

Response.Write ("<script language='javas cript'>window.o pen

(....)</script>");
---
Steven Wood

I don't think that solves the problem. It will place a
script on the returned page, but how is the script invoked
from the Server Side. The issue here is to open a pop-up
window from the server side. 'Window' is a client-side
object.

Harvey Bernstein
Jul 21 '05 #3
Hi HarveyB,

I do not believe that there is a method to open a client window without
using the client script.
For security concern, it is non-security to open a window from server-side.
Did I answer your question?

Regards,
Peter Huang
Microsoft Online Partner Support
Get Secure! www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.

--------------------
Content-Class: urn:content-classes:message
From: "HarveyB" <ha*****@compas s-soft.com>
Sender: "HarveyB" <ha*****@compas s-soft.com>
References: <01************ *************** *@phx.gbl> <uK************ *@TK2MSFTNGP12. phx.gbl>Subject: Re: Popup Window generated from Server Side
Date: Wed, 10 Sep 2003 17:50:25 -0700
Lines: 23
Message-ID: <02************ *************** *@phx.gbl>
MIME-Version: 1.0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
X-Newsreader: Microsoft CDO for Windows 2000
Thread-Index: AcN3/rAw3yfjfbmGRFOd btTXl0V14A==
X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300
Newsgroups: microsoft.publi c.dotnet.genera l
Path: cpmsftngxa06.ph x.gbl
Xref: cpmsftngxa06.ph x.gbl microsoft.publi c.dotnet.genera l:108058
NNTP-Posting-Host: TK2MSFTNGXA13 10.40.1.165
X-Tomcat-NG: microsoft.publi c.dotnet.genera l

-----Original Message-----

"HarveyB" <ha*****@compas s-soft.com> wrote in message
news:01****** *************** *******@phx.gbl ...
I would like to generate non-modal popup windows from
ASP.Net code-behind.


How about using Response.Write in your server side code:

Response.Writ e("<script language='javas cript'>window.o pen

(....)</script>");

---
Steven Wood

I don't think that solves the problem. It will place a
script on the returned page, but how is the script invoked
from the Server Side. The issue here is to open a pop-up
window from the server side. 'Window' is a client-side
object.

Harvey Bernstein


Jul 21 '05 #4
You cannot invoke windows from the server without using some form of
remoting listener loaded at the client. HTTP is get/response protocol and
doesn't work like that.

The best you can do is pass out the information to invoke the window client
side with client side script, either from a buttonclick/hyperlink or via a
script event such as onload for body. There is some code for one of these
below.
--
Regards

John Timney (Microsoft ASP.NET MVP)
----------------------------------------------
<shameless_auth or_plug>
Professional .NET for Java Developers with C#
ISBN:1-861007-91-4
Professional Windows Forms
ISBN: 1861005547
Professional JSP 2nd Edition
ISBN: 1861004958
Professional JSP
ISBN: 1861003625
Beginning JSP Web Development
ISBN: 1861002092
</shameless_autho r_plug>
----------------------------------------------

<html>
<head>
<script language="VB" runat="server">

Sub Page_Load( sender as Object,e as EventArgs)

'Form the script that is to be registered at client side.
Dim scriptString as String = "<script language=JavaSc ript> function
DoClick() {"
ScriptString +=
"window.open('h ttp://www.mvps.org',' MyWindow','widt h=500,height=50 0');}<"
scriptString += "/"
scriptString += "script>"

If(Not IsClientScriptB lockRegistered( "clientScript") )
RegisterClientS criptBlock("cli entScript", scriptString)
End If
End Sub
</script>
</head>
<body topmargin="20" leftmargin="10" >
<form id="myForm" runat="server">

<INPUT id="launchButto n" onclick="DoClic k();" type="button"
value="Submit" name="myButton" runat="server">
</form>
</body>
</html>



"HarveyB" <ha*****@compas s-soft.com> wrote in message
news:01******** *************** *****@phx.gbl.. .
I would like to generate non-modal popup windows from
ASP.Net code-behind. I have tried using Client Side
scripting like "function Test(){
window.open('te st.htm',_blank,
'height=200,wid th=400,status=n o,toolbar=no,
menubar=no,loca tion=no resizable=no
scrollable=no') ;
but I can't seem to invoke the client side script from
within a Server Side Form. I know I can use the context
with to Response.redire ct or Server.transfer to return a
different page, but can't figure how generate a pop-up
window for an 'About' page or a "Contacts" page.

Jul 21 '05 #5
The sample worked, but unfortunately I think I will need
to re-architect to do what I want. I have 3 problems.

1. The buttons are implemented inside an ASP:Datalist Cntl.
2. The plan was to encapsulate my menus in a user cntl
(ascx).
3. I am using code-behind.

Should I just go back to the drawing board. Each of the
conditions above seems to make implementing the sample
extremely difficult, if not impossible.

That is somewhat of a disappointment give that all 3 are
touted as advantages of ASP.NET.
-----Original Message-----
You cannot invoke windows from the server without using some form ofremoting listener loaded at the client. HTTP is get/response protocol anddoesn't work like that.

The best you can do is pass out the information to invoke the window clientside with client side script, either from a buttonclick/hyperlink or via ascript event such as onload for body. There is some code for one of thesebelow.
--
Regards

John Timney (Microsoft ASP.NET MVP)
----------------------------------------------
<shameless_aut hor_plug>
Professional .NET for Java Developers with C#
ISBN:1-861007-91-4
Professional Windows Forms
ISBN: 1861005547
Professional JSP 2nd Edition
ISBN: 1861004958
Professional JSP
ISBN: 1861003625
Beginning JSP Web Development
ISBN: 1861002092
</shameless_autho r_plug>
----------------------------------------------

<html>
<head>
<script language="VB" runat="server">

Sub Page_Load( sender as Object,e as EventArgs)

'Form the script that is to be registered at client side. Dim scriptString as String = "<script language=JavaSc ript> functionDoClick() {"
ScriptString +=
"window.ope n ('http://www.mvps.org',' MyWindow','widt h=500,height=50 0');}
<" scriptString += "/"
scriptString += "script>"

If(Not IsClientScriptB lockRegistered ("clientScript" )) RegisterClientS criptBlock("cli entScript", scriptString) End If
End Sub
</script>
</head>
<body topmargin="20" leftmargin="10" >
<form id="myForm" runat="server">

<INPUT id="launchButto n" onclick="DoClic k();" type="button"value="Submi t" name="myButton" runat="server">
</form>
</body>
</html>



"HarveyB" <ha*****@compas s-soft.com> wrote in message
news:01******* *************** ******@phx.gbl. ..
I would like to generate non-modal popup windows from
ASP.Net code-behind. I have tried using Client Side
scripting like "function Test(){
window.open('te st.htm',_blank,
'height=200,wid th=400,status=n o,toolbar=no,
menubar=no,loca tion=no resizable=no
scrollable=no') ;
but I can't seem to invoke the client side script from
within a Server Side Form. I know I can use the context
with to Response.redire ct or Server.transfer to return a
different page, but can't figure how generate a pop-up
window for an 'About' page or a "Contacts" page.

.

Jul 21 '05 #6
Hi HarveyB,

It seems that you want to handle the button click event in the Datalist
control.
Here is a link about it. You may have check.
http://groups.google.com/groups?q=da...hl=zh-CN&lr=&i
e=UTF-8&oe=UTF-8&selm=IzLFyfNJ DHA.2344%40cpms ftngxa06.phx.gb l&rnum=1

Regards,
Peter Huang
Microsoft Online Partner Support
Get Secure! www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.

--------------------
Content-Class: urn:content-classes:message
From: "HarveyB" <ha*****@compas s-soft.com>
Sender: "HarveyB" <ha*****@compas s-soft.com>
References: <01************ *************** *@phx.gbl> <e9************ **@TK2MSFTNGP12 .phx.gbl>Subject: Re: Popup Window generated from Server Side
Date: Thu, 11 Sep 2003 15:46:09 -0700
Lines: 115
Message-ID: <07************ *************** *@phx.gbl>
MIME-Version: 1.0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
X-Newsreader: Microsoft CDO for Windows 2000
Thread-Index: AcN4tn5CHJm1sJ8 NQaC/pNsjWjEACw==
X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300
Newsgroups: microsoft.publi c.dotnet.genera l
Path: cpmsftngxa06.ph x.gbl
Xref: cpmsftngxa06.ph x.gbl microsoft.publi c.dotnet.genera l:108210
NNTP-Posting-Host: TK2MSFTNGXA09 10.40.1.161
X-Tomcat-NG: microsoft.publi c.dotnet.genera l

The sample worked, but unfortunately I think I will need
to re-architect to do what I want. I have 3 problems.

1. The buttons are implemented inside an ASP:Datalist Cntl.
2. The plan was to encapsulate my menus in a user cntl
(ascx).
3. I am using code-behind.

Should I just go back to the drawing board. Each of the
conditions above seems to make implementing the sample
extremely difficult, if not impossible.

That is somewhat of a disappointment give that all 3 are
touted as advantages of ASP.NET.
-----Original Message-----
You cannot invoke windows from the server without using

some form of
remoting listener loaded at the client. HTTP is

get/response protocol and
doesn't work like that.

The best you can do is pass out the information to invoke

the window client
side with client side script, either from a

buttonclick/hyperlink or via a
script event such as onload for body. There is some code

for one of these
below.
--
Regards

John Timney (Microsoft ASP.NET MVP)
----------------------------------------------
<shameless_au thor_plug>
Professiona l .NET for Java Developers with C#
ISBN:1-861007-91-4
Professiona l Windows Forms
ISBN: 1861005547
Professiona l JSP 2nd Edition
ISBN: 1861004958
Professiona l JSP
ISBN: 1861003625
Beginning JSP Web Development
ISBN: 1861002092
</shameless_autho r_plug>
----------------------------------------------

<html>
<head>
<script language="VB" runat="server">

Sub Page_Load( sender as Object,e as EventArgs)

'Form the script that is to be registered at client

side.
Dim scriptString as String = "<script

language=JavaS cript> function
DoClick() {"
ScriptString +=
"window.ope n

('http://www.mvps.org',' MyWindow','widt h=500,height=50 0');}
<"
scriptString += "/"
scriptString += "script>"

If(Not IsClientScriptB lockRegistered

("clientScript "))
RegisterClientS criptBlock("cli entScript",

scriptString )
End If
End Sub
</script>
</head>
<body topmargin="20" leftmargin="10" >
<form id="myForm" runat="server">

<INPUT id="launchButto n" onclick="DoClic k();"

type="button "
value="Submit " name="myButton" runat="server">
</form>
</body>
</html>



"HarveyB" <ha*****@compas s-soft.com> wrote in message
news:01****** *************** *******@phx.gbl ...
I would like to generate non-modal popup windows from
ASP.Net code-behind. I have tried using Client Side
scripting like "function Test(){
window.open('te st.htm',_blank,
'height=200,wid th=400,status=n o,toolbar=no,
menubar=no,loca tion=no resizable=no
scrollable=no') ;
but I can't seem to invoke the client side script from
within a Server Side Form. I know I can use the context
with to Response.redire ct or Server.transfer to return a
different page, but can't figure how generate a pop-up
window for an 'About' page or a "Contacts" page.

.


Jul 21 '05 #7
Ok, then is there a way to pass a message (of some type)
to the client side so that a client side javascript can be
fired to open the window.

I mean 'message' in the most generic meaning of the term.
I just want some way to detect the button click inside the
Datalist, handle the event on the server-side and then
hand it off to the client side. The reason for this is so
that the menu inside the datalist control can be dynamic
and based on either an XML file or a SQL Query.

It seems that this should be easy, but I have tried quite
a few ideas without success.
-----Original Message-----
Hi HarveyB,

I do not believe that there is a method to open a client window withoutusing the client script.
For security concern, it is non-security to open a window from server-side.Did I answer your question?

Regards,
Peter Huang
Microsoft Online Partner Support
Get Secure! www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.
--------------------
Content-Class: urn:content-classes:message
From: "HarveyB" <ha*****@compas s-soft.com>
Sender: "HarveyB" <ha*****@compas s-soft.com>
References: <01************ *************** *@phx.gbl>

<uK*********** **@TK2MSFTNGP12 .phx.gbl>
Subject: Re: Popup Window generated from Server Side
Date: Wed, 10 Sep 2003 17:50:25 -0700
Lines: 23
Message-ID: <02************ *************** *@phx.gbl>
MIME-Version: 1.0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
X-Newsreader: Microsoft CDO for Windows 2000
Thread-Index: AcN3/rAw3yfjfbmGRFOd btTXl0V14A==
X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300
Newsgroups: microsoft.publi c.dotnet.genera l
Path: cpmsftngxa06.ph x.gbl
Xref: cpmsftngxa06.ph x.gbl microsoft.publi c.dotnet.genera l:108058NNTP-Posting-Host: TK2MSFTNGXA13 10.40.1.165
X-Tomcat-NG: microsoft.publi c.dotnet.genera l

-----Original Message-----

"HarveyB" <ha*****@compas s-soft.com> wrote in message
news:01***** *************** ********@phx.gb l...
I would like to generate non-modal popup windows from
ASP.Net code-behind.

How about using Response.Write in your server side code:

Response.Wri te("<script
language='javas cript'>window.o pen(....)</script>");

---
Steven Wood

I don't think that solves the problem. It will place a
script on the returned page, but how is the script invokedfrom the Server Side. The issue here is to open a pop- upwindow from the server side. 'Window' is a client-side
object.

Harvey Bernstein


.

Jul 21 '05 #8
Hi Harveyb,

Since the Browser/Server modal is based on request. That is to say, the
server will response to client browser with the html code at last when the
client make a request.
The server can not actively generate the html file (i.e. javascript )
without the browser request.
Have you check the suggestion of Steven, it is one method to invoke the
javascript in code behind?
Have you also check my last post that can handle the click event in the
datalist in my last post?

Did I answer your question?
If you have any related question,please feel free to let me know.

Regards,
Peter Huang
Microsoft Online Partner Support
Get Secure! www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.

--------------------
Content-Class: urn:content-classes:message
From: "Harveyb" <ha*****@panix. com>
Sender: "Harveyb" <ha*****@panix. com>
References: <01************ *************** *@phx.gbl> <uK************ *@TK2MSFTNGP12. phx.gbl>
<02************ *************** *@phx.gbl>
<jo************ **@cpmsftngxa06 .phx.gbl>Subject: Re: Popup Window generated from Server Side
Date: Mon, 15 Sep 2003 14:20:54 -0700
Lines: 85
Message-ID: <05************ *************** *@phx.gbl>
MIME-Version: 1.0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
X-Newsreader: Microsoft CDO for Windows 2000
X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300
Thread-Index: AcN7zz9LPdhNaOM yRCub/9yArgi1YA==
Newsgroups: microsoft.publi c.dotnet.genera l
Path: cpmsftngxa07.ph x.gbl
Xref: cpmsftngxa07.ph x.gbl microsoft.publi c.dotnet.genera l:108301
NNTP-Posting-Host: tk2msftngxa11.p hx.gbl 10.40.1.163
X-Tomcat-NG: microsoft.publi c.dotnet.genera l

Ok, then is there a way to pass a message (of some type)
to the client side so that a client side javascript can be
fired to open the window.

I mean 'message' in the most generic meaning of the term.
I just want some way to detect the button click inside the
Datalist, handle the event on the server-side and then
hand it off to the client side. The reason for this is so
that the menu inside the datalist control can be dynamic
and based on either an XML file or a SQL Query.

It seems that this should be easy, but I have tried quite
a few ideas without success.
-----Original Message-----
Hi HarveyB,

I do not believe that there is a method to open a client

window without
using the client script.
For security concern, it is non-security to open a window

from server-side.
Did I answer your question?

Regards,
Peter Huang
Microsoft Online Partner Support
Get Secure! www.microsoft.com/security
This posting is provided "as is" with no warranties and

confers no rights.

--------------------
Content-Class: urn:content-classes:message
From: "HarveyB" <ha*****@compas s-soft.com>
Sender: "HarveyB" <ha*****@compas s-soft.com>
References : <01************ *************** *@phx.gbl>

<uK********** ***@TK2MSFTNGP1 2.phx.gbl>
Subject: Re: Popup Window generated from Server Side
Date: Wed, 10 Sep 2003 17:50:25 -0700
Lines: 23
Message-ID: <02************ *************** *@phx.gbl>
MIME-Version: 1.0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
X-Newsreader: Microsoft CDO for Windows 2000
Thread-Index: AcN3/rAw3yfjfbmGRFOd btTXl0V14A==
X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300
Newsgroups : microsoft.publi c.dotnet.genera l
Path: cpmsftngxa06.ph x.gbl
Xref: cpmsftngxa06.ph x.gblmicrosoft.publ ic.dotnet.gener al:108058NNTP-Posting-Host: TK2MSFTNGXA13 10.40.1.165
X-Tomcat-NG: microsoft.publi c.dotnet.genera l
-----Original Message-----

"HarveyB" <ha*****@compas s-soft.com> wrote in message
news:01**** *************** *********@phx.g bl...
> I would like to generate non-modal popup windows from
> ASP.Net code-behind.

How about using Response.Write in your server side code:

Response.Wr ite("<scriptlanguage='java script'>window. open(....)</script>");

---
Steven Wood

I don't think that solves the problem. It will place a
script on the returned page, but how is the scriptinvokedfrom the Server Side. The issue here is to open a pop-upwindow from the server side. 'Window' is a client-side
object.

Harvey Bernstein


.


Jul 21 '05 #9
The replies by both you and Steven are good as far as they
go. They explain that it is possible on the server side
to create and then register a client script.

That means that a user could click a button that would
postback a request for information. If you wish to return
the info in a pop-up, non-modal window, you could generate
a script to initiate the popup.

Of course you are still left with the problem of how that
script gets invoked. Having the user press ANOTHER button
is clearly not acceptable. Using an event such
as 'onload' is only useful if there is some way for the
script to determine what/when it is to take action.
The 'onload' event would fire everytime the page was
invoked, but the window.open would be discretionary.
There needs to be some mechanism to pass a message between
server and client in order for the script to know what to
do.

The obvious possibility would be in a hidden input
control. But the client side script seems to have trouble
reading the hidden control, especially if the control is
encapsulated in a User Control. It seems the User Control
compile process pre-pends the id of the User Control to
the control id, but the script can't use that name. So
there doesn't seem to be any way for the script to read
the value of the hidden control.

This make the proposed solution either extremely difficult
or perhaps impossible. Perhaps the correct approach is to
write a Server Control. That seems like an unnecessarily
complex approach, but may be the correct way to approach
this. Perhaps User Controls are best thought of as Server-
side includes.

HarveyB
-----Original Message-----
Hi Harveyb,

Since the Browser/Server modal is based on request. That is to say, theserver will response to client browser with the html code at last when theclient make a request.
The server can not actively generate the html file (i.e. javascript )without the browser request.
Have you check the suggestion of Steven, it is one method to invoke thejavascript in code behind?
Have you also check my last post that can handle the click event in thedatalist in my last post?

Did I answer your question?
If you have any related question,please feel free to let me know.
Regards,
Peter Huang
Microsoft Online Partner Support
Get Secure! www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.
--------------------
Content-Class: urn:content-classes:message
From: "Harveyb" <ha*****@panix. com>
Sender: "Harveyb" <ha*****@panix. com>
References: <01************ *************** *@phx.gbl>

<uK*********** **@TK2MSFTNGP12 .phx.gbl>
<02*********** *************** **@phx.gbl>
<jo*********** ***@cpmsftngxa0 6.phx.gbl>
Subject: Re: Popup Window generated from Server Side
Date: Mon, 15 Sep 2003 14:20:54 -0700
Lines: 85
Message-ID: <05************ *************** *@phx.gbl>
MIME-Version: 1.0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
X-Newsreader: Microsoft CDO for Windows 2000
X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300
Thread-Index: AcN7zz9LPdhNaOM yRCub/9yArgi1YA==
Newsgroups: microsoft.publi c.dotnet.genera l
Path: cpmsftngxa07.ph x.gbl
Xref: cpmsftngxa07.ph x.gbl microsoft.publi c.dotnet.genera l:108301NNTP-Posting-Host: tk2msftngxa11.p hx.gbl 10.40.1.163
X-Tomcat-NG: microsoft.publi c.dotnet.genera l

Ok, then is there a way to pass a message (of some type)
to the client side so that a client side javascript can befired to open the window.

I mean 'message' in the most generic meaning of the term.I just want some way to detect the button click inside theDatalist, handle the event on the server-side and then
hand it off to the client side. The reason for this is sothat the menu inside the datalist control can be dynamic
and based on either an XML file or a SQL Query.

It seems that this should be easy, but I have tried quitea few ideas without success.
-----Original Message-----
Hi HarveyB,

I do not believe that there is a method to open a client
window without
using the client script.
For security concern, it is non-security to open a
windowfrom server-side.
Did I answer your question?

Regards,
Peter Huang
Microsoft Online Partner Support
Get Secure! www.microsoft.com/security
This posting is provided "as is" with no warranties and

confers no rights.

--------------------
Content-Class: urn:content-classes:message
From: "HarveyB" <ha*****@compas s-soft.com>
Sender: "HarveyB" <ha*****@compas s-soft.com>
Reference s: <01************ *************** *@phx.gbl>
<uK********* ****@TK2MSFTNGP 12.phx.gbl>
Subject: Re: Popup Window generated from Server Side
Date: Wed, 10 Sep 2003 17:50:25 -0700
Lines: 23
Message-ID: <02************ *************** *@phx.gbl>
MIME-Version: 1.0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
X-Newsreader: Microsoft CDO for Windows 2000
Thread-Index: AcN3/rAw3yfjfbmGRFOd btTXl0V14A==
X-MimeOLE: Produced By Microsoft MimeOLE

V5.50.4910.0300Newsgroup s: microsoft.publi c.dotnet.genera l
Path: cpmsftngxa06.ph x.gbl
Xref: cpmsftngxa06.ph x.gbl

microsoft.pub lic.dotnet.gene ral:108058
NNTP-Posting-Host: TK2MSFTNGXA13 10.40.1.165
X-Tomcat-NG: microsoft.publi c.dotnet.genera l
>-----Original Message-----
>
>"HarveyB " <ha*****@compas s-soft.com> wrote in message
>news:01*** *************** **********@phx. gbl...
>> I would like to generate non-modal popup windows from>> ASP.Net code-behind.
>
>How about using Response.Write in your server side code:>
>Response.W rite("<script

language='jav ascript'>window .open
(....)</script>");
>
>---
>Steven Wood
>
I don't think that solves the problem. It will place ascript on the returned page, but how is the script

invoked
from the Server Side. The issue here is to open a pop-

up
window from the server side. 'Window' is a client- sideobject.

Harvey Bernstein
.


.

Jul 21 '05 #10

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
2725
by: William Starr Moake | last post by:
The browser-based WYSIWYG editor I'm developing has a popup window with a form that generates table code from user input (width, border, cols, rows, bgcolor.) But the user has to copy-paste the generated table HTML into the editor window as it works now. How do I pass the form-generated HTML directly to the editor window so copy-paste is not...
4
22181
by: Davey | last post by:
I have a website which has a popup window (this only opens when the user chooses to open it). In the popup window I have a <select> control which lists a selection of "classes". Each class has a description and a class_id (stored in the value attribute of each option). The user will then select a class from the drop-down list. What I want...
1
11556
by: Earl Teigrob | last post by:
I did a ton of searching to try and find a simple solution to this issue and finally wrote my own, which I am sharing with everyone. In my searching, I did find a very complete and robust solution at http://weblogs.asp.net/asmith/archive/2003/09/15/27684.aspx but it was far more complex then I needed. (I got lost trying to figure it all...
7
2591
by: Drew Berkemeyer | last post by:
Hello, We have an application that we have written using ASP.NET. On one of our pages we open a popup window using javascript. The popup window has a save and a cancel button. Both of them are server-side controls and do a postback. While processing on the server we add javascript to the page load (i.e. onload=window.opener.focus();...
4
4020
by: Raed Sawalha | last post by:
Dear : In my web page I'm always checking the referer page if it was empty I do something else also I do something :0). the problem in my ASPX page client side I did a popup window, and when request Request.ServerVariables is empty for the popup window, why? thought the parent page ins (myPage.aspx). how can I get the parent page of...
12
1444
by: HarveyB | last post by:
I would like to generate non-modal popup windows from ASP.Net code-behind. I have tried using Client Side scripting like "function Test(){ window.open('test.htm',_blank, 'height=200,width=400,status=no,toolbar=no, menubar=no,location=no resizable=no scrollable=no'); but I can't seem to invoke the client side script from within a Server...
8
4928
by: Jeff User | last post by:
Hello all I am working on creating a Web application I am using C# code behind ..NET1.1 Rather than navigate to a new window, I want to open a seperate IE window when the user clicks a button. Addionally, I want to send a (query ?) string to the window to be displayed. This will be used to display additional information for the user to...
2
3574
by: VMI | last post by:
I have a LinkButton_search on my Page1.aspx that opens up a popup page called popup.aspx. I do this with LinkButton.Attributes.Add() on the Page_Load of Page1.aspx. How can I add server-side code to LinkButton_search_Click() so that the code in there runs before opening the popup window? The problem is that I fill a Session variable when I...
0
8021
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
0
8202
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
1
7787
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
1
5593
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
0
5291
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3732
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
1
2213
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1303
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
1041
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.