 |
| ASP Pro Code Clinic As of Oct 5, 2005, this forum is now locked. No posts have been deleted. Please use "Classic ASP Professional" at: http://p2p.wrox.com/forum.asp?FORUM_ID=56 for discussions similar to the old ASP Pro Code Clinic or one of the other many remaining ASP and ASP.NET forums here. |
Welcome to the p2p.wrox.com Forums.
You are currently viewing the ASP Pro Code Clinic section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
|
|
|
|

May 10th, 2004, 10:39 PM
|
|
Authorized User
|
|
Join Date: May 2004
Posts: 12
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
pop up window?
Hi,
I opened the popup window(child window) from the parent form
while the cild window is opened i want to restrict the parent window to be disable that is it must not closed when try to close the parent window
can any one help in this regard
|
|

May 24th, 2004, 12:18 AM
|
|
Friend of Wrox
|
|
Join Date: Jan 2004
Posts: 1,870
Thanks: 12
Thanked 20 Times in 20 Posts
|
|
If a user wants to close a window, they will close the window. If the only way to close a window was a close window button, this would be possible. That little X in the extreme top right cnr of your browser is out of our control using ASP - try this in a techo js forum, it's probably possible.
Wind is your friend
Matt
|
|

May 24th, 2004, 03:35 AM
|
|
Authorized User
|
|
Join Date: May 2004
Posts: 66
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
mat41,
I think u didnt get the Question wat MK asked its like modaless window in VB i guess i too hav the same probs can anybody help me
|
|

May 24th, 2004, 03:38 PM
|
|
Friend of Wrox
|
|
Join Date: Oct 2003
Posts: 336
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
you can use this example:
var sFeatures="dialogHeight: 150px;";
sFeatures += "dialogWidth: 500px;";
sFeatures += "center: yes;";
sFeatures += "edge: sunken;";
sFeatures += "help: no;";
sFeatures += "scroll: no;";
sFeatures += "status: no;";
win1=window.showModalDialog("Test.htm", "", sFeatures)
Ahmed Ali
Software Developer
|
|

May 27th, 2004, 10:01 PM
|
|
Friend of Wrox
|
|
Join Date: Jan 2004
Posts: 1,870
Thanks: 12
Thanked 20 Times in 20 Posts
|
|
I did think I understood the question. I am of the understanding; no matter what window has focus, or not. The X (window close button) can not be disabled. Am I incorrect? I remain intrigued
Wind is your friend
Matt
|
|

May 28th, 2004, 03:07 AM
|
|
Friend of Wrox
|
|
Join Date: Jun 2003
Posts: 440
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
I didn't know that, so I had to try! :)
Code:
<html>
<head></head>
<body onload="window.showModalDialog('index.html','','');"></body>
</html>
Try this simple code! I actually works as a modal dialog. Cool.
Jacob.
|
|

May 28th, 2004, 08:36 AM
|
|
Friend of Wrox
|
|
Join Date: Sep 2003
Posts: 171
Thanks: 0
Thanked 1 Time in 1 Post
|
|
You can check out DynamicDrive.com. They have a couple of modeless window scripts that you can demo.
|
|

May 28th, 2004, 07:19 PM
|
|
Friend of Wrox
|
|
Join Date: Jan 2004
Posts: 1,870
Thanks: 12
Thanked 20 Times in 20 Posts
|
|
Great, I will try it - nice little feature.
A related question if I may:
Once a window has rendered, has anybody found a way to tweak its properties. This another thing I have, thru trial and error plus word of mouth asumed not possible. (Eg.after the asp runs, tweak properties then render html)
I am aware you can run something like:
function openNewWin(pageURL, pageName, width, height, top, left)
{
newWindow = window.open(pageURL, pageName,"width=" + width + ",height=" + height + ",top=" + top + ",left=" + left + ",scrollbars=0, resizable=1,toolbar=0,location=0,status=0,menubar= 0");
newWindow.focus()
}
then start rendering. Or do the properties HAVE TO be set before any of the page code runs
Wind is your friend
Matt
|
|

May 31st, 2004, 01:29 AM
|
|
Authorized User
|
|
Join Date: May 2004
Posts: 66
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Jacob ,
Thanx a lot it just work out and very simple code
|
|

July 8th, 2004, 05:56 AM
|
|
Registered User
|
|
Join Date: Jun 2004
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Hi,
i think ur requirement is to restrict the javascript error, if u trying to access the parent window through child window
|
|
 |