I've got a button my webpage that when clicked will open another
window. Different criteria on the page will deteremine which window
gets opened when the button is clicked. I have a switch statement in my
code and then I set up javascript that I register back to the client.
This is all working fine except for one thing. The window that opens,
opens behind the parent window. I was really hoping that it would open
in front. I believe that the auto postback functionality of the button
is causing this but I'm not 100% sure.
Here's a sample of what I'm trying to do.
switch(this.cal lType.SelectedI tem.ToString(). Trim())
{
case "Meetme":
case "Dialout":
scriptblock += "<script language='JavaS cript'>";
scriptblock += "<!-- \n";
scriptblock += "var winprint=window .open('MeetMe.a spx?sakEvent=" +
SakEvent +"',null,'heigh t=900, width=1000, scrollbars',
'winprint.focus ()', 'return false');\n";
scriptblock += "// -->";
scriptblock += "</script>";
Page.RegisterCl ientScriptBlock ("clientScript" , scriptblock);
break;
case "Q&A":
scriptblock += "<script language='JavaS cript'>";
scriptblock += "<!-- \n";
scriptblock += "var winprint=window .open('QA.aspx? sakEvent=" +
SakEvent +"',null,'heigh t= 900, width=1000,
scrollbars','wi nprint.focus()' , 'return false');\n";
scriptblock += "// -->";
scriptblock += "</script>";
Page.RegisterCl ientScriptBlock ("clientScript" , scriptblock);
break;
case "Roll Call":
scriptblock += "<script language='JavaS cript'>";
scriptblock += "<!-- \n";
scriptblock += "var winprint=window .open('RollCall .aspx?sakEvent= " +
SakEvent +"',null,'heigh t= 400, width=1000,
scrollbars','wi nprint.focus()' , 'return false');\n";
scriptblock += "// -->";
scriptblock += "</script>";
Page.RegisterCl ientScriptBlock ("clientScript" , scriptblock);
break;
case "Recording" :
scriptblock += "<script language='JavaS cript'>";
scriptblock += "<!-- \n";
scriptblock += "var winprint=window .open('Recordin g.aspx?sakEvent =" +
SakEvent +"',null,'heigh t= 400, width=1000,
scrollbars','wi nprint.focus()' , 'return false');\n";
scriptblock += "// -->";
scriptblock += "</script>";
Page.RegisterCl ientScriptBlock ("clientScript" , scriptblock);
break;
}
Can anyone see what I need to add so that my new window will open in
the front> 0 1913 This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Christopher Benson-Manica |
last post by:
In some old Javascript we have, we try to determine whether the client
is IE or Netscape (assume for the purposes of this question that the
question can be resolved satisfactorily) and tailor the script to it:
var myOpen=open(url, 'subWin', 'width=600, height=400,*A*resizable=1,scrollbars=1' );
if ( myOpen && !myOpen.closed )
{
myOpen.focus();
}
*B*
|
by: D. Alvarado |
last post by:
Hello,
I am trying to open a window containing an image and I would like
the image to be flush against the window -- i.e. have no padding or
border. Can I make this happen with a single call to a window.open
function? I would prefer not to create a separate HTML page. So far
all I have is the basic
var cwin = window.open('images/KJV-THANKS.gif',
'Thanks', 'width=243,height=420,');
cwin.focus();
|
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 out). Therefore, here goes my simple "web dialog box with parent event handler fireing" solution.
...
|
by: Keshav Gadia |
last post by:
Hi,
I am an ASP.net newbie.
I am writing a user control that is made up of datagrid with one of
the columns opening a new window to display some details on click of
the set image.
I have basically used ImageButton server control.
The problem is because I have used a server control with
runat="server",the parent page is posted back and even though the
window opens up,the focus gets set to the parent window.
What I want is,the new window...
|
by: Chris |
last post by:
I know this is a dead horse I'm beating but why is it so impossible to ask
for functionality in the HTML tag to open a window/page more controllable?
why is:
<a href="somepage.aspx?value1=xyz" target="_blank">click here</a>
can't be:
<a href="somepage.aspx?value1=xyz" pagewidth="500px or %" page height="500px
or %" target="_blank">click here</a>
then what about in the code behind using:
response.redirect("somepage.aspx?value1=xyz",...
| |
by: Ralf |
last post by:
Using .NET 1.1, vb code behind.
I have a project and I have been opening new windows throughout it. I
need them opened on top of the parent, and be able to minimize or go
back to the parent if needed before closing the new window. I am
opening the window this way.
Response.Write("<script>window.open('ReviewComments.aspx')</script>")
On the code behind of the new window in the Page_Load function, I keep
the window on top by using this....
|
by: svbc |
last post by:
Hi, I am facing a problem with refreshing parent:
Parent window : A
From A I am opening a child window B using
window.open("","EVENT_DETAILS_WINDOW","height=310,width=480,top=150,left=200,status=yes,resizable=yes,scrollbars=yes");
form.target="EVENT_DETAILS_WINDOW";
form.action= "event.jsp"
form.submit();
From B I am opening a another window C and closing window B the code..
|
by: alag20 |
last post by:
Hi All,
I am facing a weird problem when opening multiple windows in my C# Winform application.
In the application I have a parent window and multiple child windows which are opened as and when user interact with the main window.
For some weird reason the child window appear for an instance and disappear behind the parent application.
I tried all of the following but nothing works -
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
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 most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
| |
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
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 instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
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 into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
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
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
|
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 effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |