Jump to content

find mouse position and/or move mouse to highlighted text


Recommended Posts

will be using sample text for the purpose of this item

issued a send("^f") command to open find box on screen

issued a send("sampletext") 

sampletext is highlighted on the page

now i want to get my mouse to move to that highlighted text so

i can get the x and y position of that text

Is this possible? 

 

 

Link to comment
Share on other sites

its a IE webpage with java as the source so  my only option

is as stated here, go to the highlighed data  and get mouse position which will 

be used to delete the item (there is a delete butto)  _ie functions do no work on 

this screen since it is java and i can't down load any products that autoit can 

interface with,, am just stuck with mouse moves, etc.. if there is no way to do this

then i will have to tell the user,,sorry no way

 

Link to comment
Share on other sites

  • Developers
1 hour ago, serena_knight said:

i really need help with this, but if it cant be done i wish someone would tell me i was thinking of using pixelsearch but dose that tell you where the highlighted text is (x,y) and if so how do you search a highlighted text (color?)

What about sharing way more details about what you want so somebody can understand and really assist? ;) 

Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

?? what kind of details? there is a highlighted text on a IE web page, Java is behind the webpage so i cant use _IE functions, if i show the source of the page and search for the highlighted text, it comes back "not found", typical of java pages. i am trying to find out if there is some kind of way to find the x,y of highlighted text, if so i can the issue a mouemove, i have considered using pixelshearch but i cant understand how to do that, does pixelsearch return x,y?

 

Link to comment
Share on other sites

  • Developers

Nice long repeat of words, but I do not see any actual information and I am terrible at guesswork. ;) 
Website?
script you test with?
Image of what you see?

Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

11 minutes ago, serena_knight said:

i have been to the help file and i find the explaination for pixelsearch hard to understand, it seems to say you can get the x,y but again it seems to say you have to supply the x,y, which of course defeats the purpose i need.

Yes you need to specify the region where pixelsearch will look at.  It could be the whole screen (slower) or a more restricted area (faster).  If you find PixelSearch hard to understand, wait till you read FAQ 31 ;)

Link to comment
Share on other sites

we can help you, for sure. but would just need a dummy java app with web-page to test with as well if you could have your devs give you a dummy you can work with. if you can share it, maybe we can try it out too and see what we see?

anyway, good luck with whatever way you choose to go. I know nothing of pixelsearch so I'm out if that's the route you go. I use UIAutomation when I can't use native AutoIt

Edited by Earthshine

My resources are limited. You must ask the right questions

 

Link to comment
Share on other sites

I think you don't understand what PixelSearch does... assuming you're referring to the included function, it looks in an area for a single pixel of the color you specify. So if you select your entire screen and give it the color blue (in decimal or hex), it will return the first pixel with the your specified color.

To get the color you're looking for, open the Au3Info tool, switch to the Mouse tab, grab the finder tool, and hover over the color you want to find. When I did this with your profile photo, it said 0xC462AC. It's a little more specific than "pink"

All my code provided is Public Domain... but it may not work. ;) Use it, change it, break it, whatever you want.

Spoiler

My Humble Contributions:
Personal Function Documentation - A personal HelpFile for your functions
Acro.au3 UDF - Automating Acrobat Pro
ToDo Finder - Find #ToDo: lines in your scripts
UI-SimpleWrappers UDF - Use UI Automation more Simply-er
KeePass UDF - Automate KeePass, a password manager
InputBoxes - Simple Input boxes for various variable types

Link to comment
Share on other sites

There are multiple ways but if you already feel pixelsearch is hard read the faq that explains find bitmap, automation. Some words to search on are bitblt and gdi+ and tesseract if its a pixelsearch. Java accessibility is another approach by looking for jabsimplespy. There is not 1 solution and even harder to help if your site is not publicly reachable.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...