AutoHotkey Community

It is currently May 26th, 2012, 7:25 pm

All times are UTC [ DST ]




Post new topic Reply to topic  [ 5 posts ] 
Author Message
PostPosted: May 2nd, 2009, 5:50 am 
I can't seem to find if the information given from WinSpector is from the top left of the control, or based on screen size or what.

I send a PostMessage, 0x201 (left mouse button down) followed by PostMessage, 0x202 (left mouse button up) to a location in an IE browser.

Should that command work regardless of screen size/resolution, or are my clicks going to be off for another user?

If they will be off, is there any way to fix this?
If they should not be off, what could I be doing wrong that would cause my clicks to not be working.

Sorry if any of this is unclear. If you have questions or need additional info please ask.


Report this post
Top
  
Reply with quote  
 Post subject:
PostPosted: May 2nd, 2009, 5:55 am 
Offline
User avatar

Joined: August 30th, 2005, 8:43 pm
Posts: 8666
Location: Salem, MA
why are you using postmessage for this? Can you use ControlClick instead? that gives you control (via CoordMode) of the window/screen issue. It's also much easier to read and understand.

_________________
Image
(Common Answers) - New Tutorials Forum - Humongous FAQ


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: May 2nd, 2009, 6:24 am 
engunneer wrote:
why are you using postmessage for this? Can you use ControlClick instead? that gives you control (via CoordMode) of the window/screen issue. It's also much easier to read and understand.


I was hoping that this was not as dependent on x,y coords, but it appears I was wrong about that. Also I was just trying to learn a little about PostMessage as I have never used it before.

Also, if it matters I have embedded the browser in a GUI via COM which has helped some. I think I might just go about this via ControlClick.

Thanks!


Report this post
Top
  
Reply with quote  
 Post subject: overkill
PostPosted: May 2nd, 2009, 6:30 am 
Offline

Joined: December 20th, 2005, 4:15 am
Posts: 165
Location: Malaysia
Engunner's right; postmessage is overkill for this task. For IE, I normally use a combo of Winactivate, ControlFocus, and Click. The classNN for the main IE window is usually Internet Explorer_Server1

Code:
WinActivate, Insert Your Window Title
ControlFocus, ahk_class Internet Explorer_Server1, Insert Your Window Title
Click 20,30


If the code runs too fast, just insert delays (Sleep, xxx) between the lines.

BTW, IE is actually more AHK-friendly than Firefox.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: May 3rd, 2009, 1:49 am 
Offline
User avatar

Joined: December 21st, 2007, 3:14 pm
Posts: 3826
Location: Louisville KY USA
wrong method al together
but hey what do i know

_________________
No matter what your oppinion Please join this discussion
Formal request to Polyethene
Image


Report this post
Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 5 posts ] 

All times are UTC [ DST ]


Who is online

Users browsing this forum: Google Feedfetcher, joetazz, krajan, over21, RaptorX, rbrtryn, SKAN, Xx7 and 73 guests


You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Group