Free

Free coded apps to suit all. No sign up, no email, usable offline, updates when I can, feedback welcome. Send feedback

Thinking

Can a macro record scrolling and drags?

Yes. Macro by Zaweba records drags with their whole path and scrolling in both directions, along with clicks, double-clicks, typing and the timing.

Can a macro record scrolling and drags?

Yes. Macro by Zaweba records drags with the path the mouse took, and scrolling in both directions, as well as clicks, double-clicks, keystrokes and the time between them. You don't switch anything on for this. Press Ctrl+Alt+R, do the job, press Stop, and the drags and scrolls are there in the step list.

Several wheel notches in a row merge into one Scroll step, so a long scroll down a page doesn't turn into dozens of lines in the editor.

How drags are kept

A drag is a press of a mouse button, a movement and a release. Macro keeps the path of that movement as part of the drag, so dragging a file into a folder, moving a slider or drawing a selection box replays the way you did it.

This is separate from the Record mouse moves setting. That setting, off by default, keeps every movement of the mouse, sampled every 15 ms, even when no button is held. You don't need it for drags, because the drag's own path is kept anyway. Leaving it off keeps the macro short and easy to read.

In the step editor you can also build drag style actions by hand, using the steps that press a button, move and release it. That's handy when a recorded drag needs adjusting or when you'd rather type positions than record them.

How scrolling is kept

Scroll notches merge into one Scroll step, up or down. When you replay, the same amount of scrolling happens at that point in the macro. If a page has grown since you recorded it, the same scroll may not bring the same thing into view, so it's worth checking what's on screen after a scroll before relying on a click that follows.

Recording drags and scrolls well

Move steadily. A drag that hesitates at the start or end may drop in a slightly different place when replayed, especially at higher speeds. Let go deliberately over the target.

Wherever you can, record against a window that will be in the same place next time. Turn on positions relative to the active window and clicks and positions are measured from that window's corner, so the macro still works after the window moves. You can switch each step between window and screen positions in the editor.

If the job scrolls and then clicks, add a short Wait step after the scroll. Pages often take a moment to settle, and a click that arrives during that moment can miss.

Replaying them

Replays can run at 0.5x, 1x, 2x, 3x, 5x, 10x or with No delays. Waits and typing pauses scale with the speed. Drags and scrolls are usually the first things to go wrong at very high speeds, because the program under the mouse has to keep up. If a macro with drags misbehaves, slow it down first and see whether it settles.

A countdown, 3 seconds by default, comes before each replay. It never takes the focus and clicks pass through it, so you can click into the target window. If a drag goes somewhere you didn't expect, hold Esc for one second. The replay stops before its next event and lets go of any mouse button it was holding, so you aren't left with a drag stuck halfway.

When a recorder isn't the right tool

Some drags depend on what is under the mouse at that moment, such as dropping onto whichever item happens to be at the top of a list. A recording repeats positions, not decisions, so jobs like that need the list to be in the same order each time. For fixed layouts, such as moving the same panel or nudging a slider to the same point, a recorded drag is reliable and quick.