Quantcast
Channel: AutoIt v3 - General Help and Support
Viewing all articles
Browse latest Browse all 12506

How to scroll a Window horizontally?

$
0
0
I need to scroll a window both horizontally and vertically.
I have already achieved vertical scrolling using the following code:

$MainWindowTitle = "Example"
$controlID = "[CLASSNN:Window8]"
$windowPos = ControlGetPos ( $MainWindowTitle, "", controlID )
WinActivate ( $MainWindowTitle )
; Position the mouse over the scrollable area.
MouseMove( $windowPos[0] + 10, $windowPos[1] + 10, 0 )
; Scroll
MouseWheel ( "down" )


The problem with using similar code to scroll horizontally, is that it appears AutoIt has zero support for horizontal mousewheel.

So then I tried using arrow keys:

ControlSend ( $MainWindowTitle, "", $controlID, "{RIGHT}" )


But this has no effect. In fact, the window appears to not respond to arrows from my actually keyboard either, but I thought it was worth a shot.

Just to be clear, the window does indeed have a scroll bar and can be interacted with using the mouse.

Is my only option to send MouseClick's to the little arrows on the sides of this scrollbar?
Or is there some AutoIt method (crosses fingers) that I've not yet discovered that will make this job very simple?

Viewing all articles
Browse latest Browse all 12506

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>