Re: Window Location(s)

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



Justin,
would you be able to post the article link so I can read how this is
applied? I'm calling the window.open from C#. I'm not sure how I would
apply your example since I'm such a genius in Java.


--
Homer J.


"S. Justin Gengo" wrote:

Homer,

This may work for you - I found it in a post on another site:

You can't specify the monitor, but you can specify the position of the popup
window as being relative to the where the click caused the window to popup.

Use the getMouseXY() function to get values to pass as the left and top args
to the window.open() method. (the left and top args only work with V3 and up
browsers).

window.open docs: http://www.javascripter.net/faq/openinga.htm

function getMouseXY( e ) { if ( event.clientX ) { // Grab the x-y pos.s
if browser is IE. CurrentLeft = event.clientX +
document.body.scrollLeft; CurrentTop = event.clientY +
document.body.scrollTop; } else { // Grab the x-y pos.s if browser
isn't IE. CurrentLeft = e.pageX; CurrentTop = e.pageY; }
if ( CurrentLeft < 0 ) { CurrentLeft = 0; }; if ( CurrentTop < 0 ) {
CurrentTop = 0; }; return true;}

--
Sincerely,

S. Justin Gengo, MCP
Web Developer

Free code library at:
www.aboutfortunate.com

"Out of chaos comes order."
Nietzsche




"Homer J." <KillingComputers@xxxxxxxxxxx> wrote in message
news:4C8A34DE-88E8-4111-B429-32A28338FDF2@xxxxxxxxxxxxxxxx
I have a web page that has a popup that is opened via window.open. No
problems here. The web app that I'm writing will be used by folks that
run
dual monitors. How can I have that popup open on the same monitor that
the
parent is on?
--
Homer J.


.



Relevant Pages

  • Re: Window Location(s)
    ... This is all fine and dandy if there's only 1 monitor. ... "Homer J." ... but you can specify the position of the popup ... window as being relative to the where the click caused the window to popup. ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Window Location(s)
    ... You can't specify the monitor, but you can specify the position of the popup window as being relative to the where the click caused the window to popup. ... Use the getMouseXYfunction to get values to pass as the left and top args to the window.openmethod. ...
    (microsoft.public.dotnet.framework.aspnet)
  • How can get the user name and extension number list
    ... I 'm programming a software which can monitor a user or an extension. ... When there is a call coming, the software will popup a window for this ...
    (microsoft.public.win32.programmer.tapi)
  • Re: Title bar of Windows form is stuck in resize state when x coordina
    ... The bug is in these two lines, that will always result in positive ... It passes the hwnd of the external owner window as m_iHwnd. ... the problem wiht the title bar does not happen. ... In the monitor settings dialog, drag monitor 2 so that it is to the ...
    (microsoft.public.dotnet.framework.windowsforms)
  • Re: Iceweasel freezes and iceape vulnerabilities and instability
    ... popup is fixed in place within the browser window, ... the browser is doing its job; it is just possible to do some really ... Funny you mention this -- I don't think this is due to malicious code, ...
    (Debian-User)