I'm running the below script to open a popup window. Works great!
I'd like to find out if there's a way to include Mouse Coordinates in
the top and left parameters so that when my button is clicked, the
popup opens in the same location.
protected void btnLocateEmpID_Click(object sender, EventArgs e)
{
StringBuilder sb = new StringBuilder();
sb.Append("<script>");
sb.Append("window.open('LocateEmpID.aspx', '','toolbar=0,
height=320,width=375,resizable=0,scrollbars=0');") ;
sb.Append("</scri");
sb.Append("pt>");
Page.RegisterStartupScript("test", sb.ToString());
}
Please be as descriptive as possible with your reply.
Thanks for your help! ;-) 3 3730 http://msdn2.microsoft.com/en-us/library/ms536651.aspx
-- http://www.eggheadcafe.com
unBlog: http://petesbloggerama.blogspot.com
BlogMetaFinder: http://www.blogmetafinder.com
"Dave" wrote:
I'm running the below script to open a popup window. Works great!
I'd like to find out if there's a way to include Mouse Coordinates in
the top and left parameters so that when my button is clicked, the
popup opens in the same location.
protected void btnLocateEmpID_Click(object sender, EventArgs e)
{
StringBuilder sb = new StringBuilder();
sb.Append("<script>");
sb.Append("window.open('LocateEmpID.aspx', '','toolbar=0,
height=320,width=375,resizable=0,scrollbars=0');") ;
sb.Append("</scri");
sb.Append("pt>");
Page.RegisterStartupScript("test", sb.ToString());
}
Please be as descriptive as possible with your reply.
Thanks for your help! ;-)
Peter, that link basically tells me what I already have in my original
posting. Thank you all the same. My Original Posting says that the
script I had worked Great. My original question...How Can I get
"Mouse Coordinates" (X,Y) to include them as Left and Top parameters
so that the popup window opens "where the button was clicked"? That
link doesn't provide that.
On Nov 10, 10:56 am, Peter Bromberg [C# MVP]
<pbromb...@yahoo.NoSpamMaam.comwrote:
http://msdn2.microsoft.com/en-us/library/ms536651.aspx
--http://www.eggheadcafe.com
unBlog:http://petesbloggerama.blogspot.com
BlogMetaFinder: http://www.blogmetafinder.com
"Dave" wrote:
I'm running the below script to open a popup window. Works great!
I'd like to find out if there's a way to include Mouse Coordinates in
the top and left parameters so that when my button is clicked, the
popup opens in the same location.
protected void btnLocateEmpID_Click(object sender, EventArgs e)
{
StringBuilder sb = new StringBuilder();
sb.Append("<script>");
sb.Append("window.open('LocateEmpID.aspx', '','toolbar=0,
height=320,width=375,resizable=0,scrollbars=0');") ;
sb.Append("</scri");
sb.Append("pt>");
Page.RegisterStartupScript("test", sb.ToString());
}
Please be as descriptive as possible with your reply.
Thanks for your help! ;-)- Hide quoted text -
- Show quoted text -
Dave wrote:
Peter, that link basically tells me what I already have in my original
posting. Thank you all the same. My Original Posting says that the
script I had worked Great. My original question...How Can I get
"Mouse Coordinates" (X,Y) to include them as Left and Top parameters
so that the popup window opens "where the button was clicked"? That
link doesn't provide that.
It's kind of messy in implementation on a per-browser basis.
Scroll down until you see the Mouse Position heading. http://www.quirksmode.org/js/events_properties.html
Chris. This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Les |
last post by:
Hi,
I'd like to find out how to use the window.open() script in Fireworks MX. I have posted my question in the Fireworks forum but
didn't get any replies. Since it's javascript, maybe someone...
|
by: Dan Cruz |
last post by:
Below are two files: Main.asp and Help.asp.
I've stripped it down to the 'barest-of bones' so that anyone willing to
help can duplicate the problem on their own systems.
***Main.asp*** looks...
|
by: Richard Bell |
last post by:
I'm a bit new to Javascript and am trying to do
oNewWin = window.open( ... );
then determine when the contents of oNewWin are completely loaded.
I've tried
oNewWin.attachEvent( "onload",...
|
by: Dominic Tocci |
last post by:
I'm searching for a way to use window.open on my web page to open a window
in firefox that allows the sidebars to work (bookmarks, history, etc).
When I use the following:
var...
|
by: Fowler |
last post by:
1.) i want to open a browser when click a button
the browser can only be open ONE only, no TWO can be open!
|
by: Seth Grimes |
last post by:
Hello all,
I want to open a window when a user leaves my site. I set up a function
called by onUnload. To skip the window.open if the user hasn't left my
site, I set a variable in my links and...
|
by: NC |
last post by:
Hi All,
We have an issue where if we say:
window.open(uri, 'QuickTradePopup',
'width=730,height=300,menubar=no,toolbar=no,scrollbars=yes,resizable=yes').
|
by: Dave |
last post by:
For some reason, the below lines only work on select machines. All
machines are running IE6. IE SP's and OS's vary. When it doesn't
work, default.aspx (the page that this code is in) opens and...
|
by: arajunk |
last post by:
In Firefox this opens a full size window (maximized) . In IE it opens
the partial window requiring user to click restore (upper right) to
maximize. What am I missing ?
var...
|
by: Dave |
last post by:
I'm running the below script to open a popup window. Works great!
How Can I get "Mouse Coordinates" (X,Y) to include them as Left and
Top parameters
so that the popup window opens "where the...
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: emmanuelkatto |
last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud.
Please let me know.
Thanks!
Emmanuel
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
|
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,...
|
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,...
|
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...
|
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...
|
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...
| |