Cannot Use Screen Capture

I feel like a dunce asking this, but how do you take a screenshot, add it to your clipboard, and then paste it?

For example, if I use this:

And then paste it, I get this (note: this the picture from my clipboard):

But then when I switch windows, and press the hotkey again, it still gives me the same picture above.

Can anyone please help? I cannot seem to use any screenshots.

Use the System Clipboard.

Thanks. I tried that before (see below) and it still doesn't paste.

If that's not working I have to question whether the macro is firing at all.

  • You've made sure the macro is working properly?
  • Where are you trying to paste?
  • Have you tried capturing different windows?

Please post an actual copy of your macro:

Sure thing (and thanks for your help):

Take a snapshot of the front window.kmmacros (1.5 KB)

All I'm trying to do is:

Press a hotkey (or typed string).
Take a screenshot of the front window and keep it on my clipboard.
When ready, I can manually paste the screenshot where needed.

Hope this explanation helps.

I don't seen anything weird about your macro, and it works fine for me on my Mojave system with Keyboard Maestro 10.2.

Are you running the KM Clipboard History Switcher?

If so – is the image showing up in your clipboard history?

I wasn't running the switcher (I've no idea what that does). I just enabled it. I tried running the macro and again and it does not show in the history.

  • Put a beep in your macro, and make sure it's running – and make sure you haven't disabled the macro or its parent macro group.
  • Try running the Interactive Help in the Keyboard Maestro Editor Help menu.

Thanks, I was just reading that article. :slight_smile: Still not sure what its purpose is...

What do you mean by "beep"?

The macro is enabled.

Interactive Help said the following:

It keeps a history of what's been copied to the clipboard...

If you can't envision the utility of that then Google is your friend.

You know how to search the Keyboard Maestro Editor and/or the Keyboard Maestro Wiki?

image

image

Chris has shown you how to find the "beep" action -- it's a useful debugging tool because it gives an audible indication that the macro has run.

I'm not sure it has -- at least, not run without errors -- because your pictures above are not what the macro should produce. You should be getting the entire front window, not a portion of it. But if it isn't working you should get a Notification of the failure -- have you allowed Notifications from KM?

One thing to watch -- if you don't have a window open in the active app, the macro as written will fail, though you should get a Notification. Try adding the following action at the end of the macro:

image

That'll get you a dialog telling you with "OK" if the screen capture action was successful or the error if it wasn't.

By "switch windows", do you mean switch apps? Have you checked your group settings? If your macro is in a group that's only available in the KM Editor, it won't work in other apps.

Thanks for this.

Chris has shown you how to find the "beep" action -- it's a useful debugging tool because it gives an audible indication that the macro has run.

I'm not sure it has -- at least, not run without errors -- because your pictures above are not what the macro should produce. You should be getting the entire front window, not a portion of it. But if it isn't working you should get a Notification of the failure -- have you allowed Notifications from KM?

Thanks for mentioning this. I've enabled Notifications now and the Notification says "Action Failed. Notification" followed by "Display Text. Notification". Any ideas?

Also, I think the partial image only occurred because I clicked the gear icon in the top of the action and selected "Copy as image." Which I realize now just refers to that action and not the macro itself. Sorry for any confusion!

By "switch windows", do you mean switch apps? Have you checked your group settings? If your macro is in a group that's only available in the KM Editor, it won't work in other apps.

Yes, I meant "switch apps". The macro is in the Global Macro Group, so it should work on all settings.

Thanks, I did get a beep but the notification said it failed. If it helps, I had an issue with pasting before (on a macro that worked fine for years). The details are here if you think the background would help: Ctrl-V Doesn't Work for Macro Anymore, But Ctrl-B Does? - #15 by cozandeffect1

Sounds like your Notifications aren't quite right still. Change the "Display Text" action you added to "Display text in a window" (as above) and turn off the "Screen Capture" action's "Notify on Failure" option so that KM uses its own dialog rather than going through the OS Notifications system -- that might get you a proper error message from the "Screen Capture" action.

Thanks. I've done both and get this when I run the macro:

It works! I've no idea why that change would fix the macro, but it now pastes like I wanted. (Also, it shows up in the Clipboard History Switcher.)

Thank you SO much for your help, everyone!

... and for some reason it stopped working. It only worked once yesterday. And I haven't changed anything. Does anyone have any suggestions?