467,911 Members | 1,442 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 467,911 developers. It's quick & easy.

Track Mouse Coordinates Outside Window

How can I track the mouse coordinates outside the active window? No
one can tell me its not possible because Google Spreadsheets and
EditGrid both do it. When you drag down to select cells these
spreadsheet programs are capable of properly selecting the cells based
on where the mouse is, even though the mouse is way outside the
browser. I haven't been able to find any info on it or figure it out
myself. How is this possible?

Dec 17 '06 #1
  • viewed: 5145
Share:
4 Replies
No one?

Dec 18 '06 #2
at*****@hotmail.com wrote:

Hi,
How can I track the mouse coordinates outside the active window? No
one can tell me its not possible because Google Spreadsheets and
EditGrid both do it.
Sure I can :)

That is not possible, sorry. The MOUSEMOVE listener has to be registered
on some DOM element, and it won't follow the mouse moves that happens
outside of this element.

I have just tried Google Spreadsheets, using Firefox 1.5. I have reduced
the window so that it occupies 1/4 of my desktop, have started some
selection in the sheet and then have moused outside of the window. The
program does not follow the mouse moves, it simply continues moving the
selection towards the direction I had set when I left the window (in the
meanwhile I've been clicking and writing to another window, some MS Word
document, and the selection kept expanding).

Could you explain why you need this feature? People around here have
been solving lots of design issues, and yours may already have received
some nice solution!
Kind regards,
Elegie.

PS : If you're working in some secure and known environment, you could
probably design some external component that would capture the mouse
position, and use it directly from your script. The technology used
would depend on the targeted platform and browser.
Dec 18 '06 #3
Lee
at*****@hotmail.com said:
>
No one?
One excellent way to make sure you don't get many responses is to
say "No one can tell me...".
--

Dec 18 '06 #4
Didn't mean to be rude :)

Actually you're right, it doesn't work in Firefox but it does work in
Internet Explorer, so IE must have a proprietary thing going on. I
should have mentioned that.

Dec 19 '06 #5

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

10 posts views Thread by Danny | last post: by
7 posts views Thread by RobKinney1 | last post: by
2 posts views Thread by quickcur | last post: by
16 posts views Thread by dfaber | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.