Paste In Order Copied

Sorry to hear that.

I'm running Keyboard Maestro 9.0.4 on macOS 10.14.6 (Mojave), and these macros still work fine for me.

Please post your error messages, screen shots, and the details of a simple example that does not work, and which versions of KM and macOS you are running.

If nothing is working, then please see Troubleshooting -- Something Unexpected is Happening.

This is great!
One issue I am having is I need the pasted txt to be in plain text.
When I add "Filter system keyboard with remove styles" and run
the paste in order macro, it skips my first copied clipboard item.
In other words, if i copy five items, then when I run the macro it
pastes this way: two, three, four, five, five.

I've tried dragging the Filter action to different chains in the macro with no fix.
I am a complete newbie to the program so not sure how to do this.
This is where the added filter action currently sits in the chain:
Screen Shot 2020-04-18 at 2.24.42 PM

I just uploaded a new version that provides an option to paste as PLAIN text.

FYI, here are the key changes I made.
Basically, you set a KM Variable to the Past Clipboard, and then set the System Clipboard to that variable. Since KM Variables contain only plain text, that does the conversion.

Replace This:
image

With This:
image

Awesome! Thanks for the addition, and thanks for the explanation. That makes more sense now.

1 Like

Thanks very much for the macro !
I find that I often have to paste multiple clips, but not in order copied. This makes sense when I am compiling information from different sources and want to create a final synopsis.
My gut feeling is that this is a common problem.
Would you have a suggestion on how to proceed ? Could I add an initial step where the clipboard is displayed → I select clips → clips are pasted in order of selection.
thanks again

If you turn this button in the clipboard history window off:

The window will stay open until you close it, making it easy to paste multiple things in any order you want (though note that any clip selected will rise to become the top item in the history when pasted, which is understandable when you realize it's being set to the current system clipboard contents, but can still be non-intuitive if you don't expect it to happen).

3 Likes

thanks for your reply, the screenshot and the very useful tip.
I am sorry but there is something that I don't get:

  • I still can't figure out how to paste in order of selection (not in order copied)
  • using your solution, I can't take advantage of @JMichaelTX 's macro (or is there something I don't understand)
    thanks again

Right, you don't need the order copied macro with this method. The idea is that you just open the regular KM clipboard history window, scroll up and down as necessary, and use Enter or double click to paste the clips you want wherever they appear in the history until you're done, at which point you manually close the window.

1 Like

Yes but are you able to select the order of the clips using the method you describe thank you again

As I said above:

1 Like

OK, I get it. thanks very much !

1 Like

Was there every anything more on this issue with only the first paste happening? I am using Version 2.0 with KM 9.2 on Big Sur. I previously would use this macro to copy a bunch of individual key not slides and then paste them in order into a message, but noticed in the last few months that I see the same issue as mentioned above with Chrome, where the Macro does the first paste, but then seems to pause and then if I select things which can accept paste of keynote slides it will paste the remainder into that. If I type Ctrl-V again it will start another instance of the macro, although on occasion I have noticed it may actually emit the second slide in the process, although not consistently. Any ideas?

I don't have access to Big Sur, so I can't test nor diagnose issues on that macOS.

But, if you can post a narrated video showing the complete process, perhaps I can spot something that will help resolve the issue. You can upload the video to a variety of cloud services, including DropBox (and then get the Public link), YouTube (using the unlisted option), or services like CloudApp. I often use Dropbox for small, short videos.

Hi @JMichaelTX,

First of all, thanks a lot for sharing these macros. I did not notice it. I had some test, it works great, except for one minor issue: The custom delimiter does not work.

I went back to exam the macro and found out that the option of "Custom" is missing for the variable DND_CAP__InsertBetweenPastes.

|%Variable%DND_CAP__InsertBetweenPastes%|Return|Tab|Space|LIneFeed|HorizontalLine|Nothing

If I insert this option, choose this option in the Prompt window, and put the custom delimiter, it works as excepted.

|%Variable%DND_CAP__InsertBetweenPastes%|Return|Tab|Space|LIneFeed|HorizontalLine|Nothing|Custom

I guess the better way might be to add another "IF-ELSE" action:

IF: the custom delimiter is not empty, 
Then: use the custom delimiter.
Else: use the default delimiter as designated by the user in the Prompt window.

Blessings,
Martin

Here is what I mean:

I keep the variable DND_CAP__InsertBetweenPastes as is, i.e., not adding Custom as the option.

|%Variable%DND_CAP__InsertBetweenPastes%|Return|Tab|Space|LIneFeed|HorizontalLine|Nothing

I added a condition action. If the variable DND_POC__CustomDelimiter is not empty, i.e., user has put something in the custom delimiter. Then ignore the variable DND_CAP__InsertBetweenPastes. This way, I don't need to worry about the options in that field. My custom delimiter will override that field.

If the variable DND_POC__CustomDelimiter is empty, then I need to choose an option from the variable field DND_CAP__InsertBetweenPastes to be set as a delimiter. (I moved the "set variable DND_CAP__Delilmiter action to the "Then" statement and everything else to the "Else" statement.

image

Also, what is the difference between "Return" and "Linefeed"?
When should I use "Return" and when should I use "Linefeed"?

Edit: change "Enter" to "Return".

Edit 2:
I was reading this:

It says:

Mac OS used CR for years until OS X switched to LF.

Maybe we don't need "Return" at all? :thinking:

@martin, thanks for your feedback and suggestions.
I am very busy right now on another project, so it may take me a few days, even a week, to analyze your suggestions and make any needed updates. But I will get to it.

1 Like

When I run this I get an error. "Set Variable to Calculation failed to evaluate DND_CAP__NumCB. DND_CAP__NumPaste. Macro "Past Order Copied" cancelled (while e:...

Then I can't read the rest because the notification only shows a certain number of characters. Does anyone know what this means?

You can grab notifications at the bottom and drag to enlarge them.

You can also look in the Keyboard Maestro Engine log to read the whole entry.

You can find the KM logs folder by looking in the Keyboard Maestro Editor's Help menu.

Here is a useful macro:

Open the Keyboard Maestro Engine Log in the Console or BBEdit

5 posts were split to a new topic: Copy List of Filenames and use to Rename other Files