Jump to content

Newbie Question - how to select large text area


Recommended Posts

Posted

Hi All,

Just started with AutoItX v3 in vbscript. I open a web page and then I want to select a body of text and then copy this onto hte clipboard to paste into excel - this I can do if the text area is small but I do not know how to select and scroll down off the screen.

Any help is much appreciated.

Cheers

-S

Posted

You should be able to click somewhere (where you want the copying to begin) and then send {SHIFTDOWN} followed by anough {DOWN}'s to cover the text area.

Ex: (I'm going to just give you the AutoIt commands, I'm not familiar with VBScript)

MouseClick("left", x, y)

Send("{SHIFTDOWN}{DOWN 10}{SHIFTUP}{CTRLDOWN}c{CTRLUP}")

; This will select 10 lines down from the MouseClick and copy it.

************************************************************************

Alternatively, if you just want to select the entire page, try using a CTRL+A Keystroke to select all and then the CTRL+C keystroke to copy it.

Send("{CTRLDOWN}ac{CTRLUP}")

; This will select the entire page and copy it.

Posted

I believe this works just as nicely.

Send("^a^c")

<{POST_SNAPBACK}>

ah yes, I wasn't sure if that worked or not... for some reason I was thinking that would push CTRL, release CTRL and then push a... thanks for the tip

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
×
×
  • Create New...