User Input Question - Entering Unique Page Numbers from a Cut'n'Paste Macro

Hi there,

I have created a macro for copying and pasting citations into OmniOutliner. I use EndNote as my citation manager and the format of the pasted citation is:

{author_surname, YYYY #Record_Number}

However, this doesn't include a pinpoint reference, which I normally enter manually by adding an '@' followed by the page number before the last '}'. So the completed citation looks like this:

{author_surname, YYYY #Record_Number@[page_number]}

I was wondering whether it is possible for Keyboard Maestro to prompt me for the page number when it is running the macro? I have tried using the 'Prompt for User Input', creating a variable called 'page number' and leaving the default value field empty. Then I set the variable 'page number' to text '%Variable%Page Number%', but the page number doesn't appear.

I was wondering if anyone could help me figure out why its not working? I have exported and attached the macro if that helps.

Thank you, in advance, for your assistance!

Aaron
Research Compiler.kmmacros (8.9 KB)

Howdy,

Since I use neither Omni Outliner nor EndNote, I am not exactly sure what's happening onscreen, or what the control-command-H hotkey does. But I can help clarify something you seem to have misunderstood, and perhaps that will help you correct your macro.

You're prompting for user input here. After the window appears and you enter a number and press OK, that number is immediately assigned to the Page Number variable. That's all fine and dandy, but in the next step you're assigning the Page Number variable to itself. This is a redundant step. I believe what you want to be doing is Inserting Text.

Try what I've uploaded and let me know if it works.

Research Compilerv2.kmmacros (8.8 KB)

Good luck!

1 Like

Thank you, that makes so much sense. And, I’m happy to report, that fixed it! It works perfectly.

Also, the control-command-H hotkey highlights the selected text so the extract is easier to find if I need to go back to the original source.

Thank you so much for your help!

You’re very welcome, @Aaron.