Find the flagged rows

A 200-row ledger scrolls inside its own well. Twelve rows are flagged, most of them below the fold, and every row carries the same Review button. Clicking every blue button is 12 right and 188 wrong, so the flag is the thing to find. Build a macro that scrolls, detects the amber flag, and Reviews only the flagged rows.

scroll + find detect the flag below the fold Free 15 min

This is the lab where detection earns its keep. A plain macro replays fixed positions, but the flagged rows sit at different places every time you scroll, and ten of the twelve start out below the fold. So you cannot just record twelve clicks. You teach the macro to watch for one thing (the amber flag), click the Review next to it, scroll down, and keep going. Detection is Free in QHuman, and so is everything this lab uses.

Open the target first. It opens in a new tab. Point QHuman at it and read its instrumentation panel as you go.

Open Long Ledger
Every row has the same blue button, so clicking Review on an unflagged row scores a wrong click. The amber chip is the only thing separating the twelve rows that matter from the 188 that do not. R resets the counters, jumps back to the top, and reshuffles which rows are flagged, so you cannot learn their positions. F hides the panel and widens the ledger for a clean capture.

Build the macro

  1. Make the macro, then open the Detection view Click New Detection and name it Flag Sweep, then open the Detection view and pick Flag Sweep in the Macro: picker. Put the Long Ledger where you can see the whole card, and leave it there: every coordinate you capture depends on it not moving.
  2. Add the review step, and snip the amber flag Add a step named review flagged. Being first, it becomes the start on its own. Open it and add a click: set Find: to Image and press Capture snippet.... Capture only lives inside this dialog, so the step and its snippet happen together. Take a tight piece of the flat amber chip, and leave the dialog open: the next step keeps configuring it.
  3. Offset the click from the flag to the button You found the flag, but you have to click the Review beside it. Leave Click point on the match: on Center and put the distance into Offset: instead: about X 114, Y 0 on the target's default layout (measure your own rather than trusting that number).
    Nothing here is a fixed screen position, which is the point: the same two numbers work for a flag on row 4 and a flag on row 177, at any scroll position, because they are measured from the thing QHuman just found.
  4. Add a scroll step to reach below the fold Add a second step called scroll. Use Add sequence... to play a short recorded scroll: a few wheel ticks with the pointer over the ledger. Keep it short, well under a screenful: a big scroll jumps past flagged rows between sweeps, and the loop only catches a flag it can actually see. Record that separately first, and turn on Record mouse scroll under Settings → Recording before you do: it is off out of the box, so a scroll recorded without it is an empty macro. After the scroll sequence, add Add advanced ▾ → Wait a random moment..., about 0.4 to 0.6 s: that pause lets the ledger settle before the loop looks again, so the first detect after a scroll does not fire mid-scroll and click where the flag was.
  5. Wire the transitions into a loop On review, under Then: go to the next step (first match wins), Add a first transition: When a target is found / absent, is found on screen, pointing back at review, so it keeps clearing flags while it can see one. Add a second, is NOT on screen, pointing at scroll. On scroll, Add an Always (every time) transition back to review. Order matters on review: the first match wins.
    Two steps, three edges: clear what you can see, scroll when you cannot, come straight back. The self-loop on review is what empties a screenful before moving on. Read the two edges off review in order, found first, not-found second: swap them and it scrolls straight past every flag it was standing on. This loop also has no exit, and a timed one will not help: a timeout only fires when nothing else matched, and here one of those two edges always matches. You stop this one yourself.
  6. Rehearse with Try it (dry run) The review step is already the start, so there is nothing to set. Two checks, in two places. Inside the review click's dialog, use Test detection... to preview what the flag matches right now. Then on the canvas, Try it (dry run) and Start walk the whole flow with every action suppressed, and Event timeline shows each attempt as it happens. This is the only run where you get to watch.
  7. Reset the ledger and run it Nothing to confirm: the Detection view saves as you go, and its Detection tab should read configured - 2 states, starts at 'review flagged'. Back on Macros, use Play All: press R on the target, then play. Watch the target, not QHuman: the window hides itself and there is no log to read. Stop it once Flagged handled reads 12 / 12, since nothing ends this loop for you. To bail out, slam your mouse into a screen corner: the fail-safe is on by default, under Settings → Playback.
Checkpoint

Three numbers, and only the third one is hard to earn. Wrong clicks at 0 is the whole lab, because a macro that just clicks every Review button also finishes at 12 / 12.

On a real ledger those 188 are 188 things you did not mean to touch, and nothing would have counted them for you. Press R and run again: Missed stays amber at 0, which is the colour, not a warning.
Make it yours

Now prove it is detection, not memory. Press R to reshuffle the flagged rows to new positions, then run your same macro unchanged. Because it watches for the amber flag and scrolls, it should still land 12 of 12 on a completely different layout. If it does, you built a detector, not a recording.

If it went wrong

  • Wrong clicks climbing The macro is Reviewing rows that are not flagged. The click is landing on a Review button by position, not on the flag. Re-aim Add click… at the flag match with an offset to the Review, and shrink the capture so only the amber chip matches.
  • Missed stays above 0 Flagged rows further down never got reached. Two causes: the scroll is not moving the ledger well (keep the pointer over the list), or each scroll is too big and jumps past flags between sweeps (shorten it to well under a screenful). Let the loop repeat until the flag is absent across the whole ledger.
  • The first click after a scroll lands off The detect fired before the ledger's scroll settled, so the click aimed where the flag was mid-scroll. Add a short Wait a random moment (about 0.4 to 0.6 s) to the scroll step, after the scroll sequence, so the loop only looks again once the rows have stopped moving.
  • It never stops on its own By design. One of the two transitions always matches, so there is no exit to add: a timed After 5s transition can never fire (something always matches first), and a flag-absent exit would quit early while flagged rows are still below the fold. Let it run, watch Flagged handled reach 12 / 12, and stop it yourself.
  • The flag never matches The capture region is off, or it is scanning too much screen. Limit the condition to the ledger's flag column and confirm it with Test detection… before running the whole macro.

Stuck?

Grab the finished macro. Download it and open QHuman's Import shared file... to load it, then compare its detection graph to what you built. It is a reference to read, not a macro to run: the detection snippet inside was captured on another screen, so it will not match your display. Run with the one you took in the lab instead.

Download the solution (.qhz)

Keep going

Want the full detail behind steps, conditions, and click-on-match? Read the detection guide. Ready for the next lab? Next up is Work the order queue, where you open each order, read its recommendation, and branch three ways.