How do I get a Macro to ask me for numerical keystrokes?

I have recorded a macro using the record feature. When recording I had to type in a number, which KM recorded as a separate action for each number. (See screen shot) I need to replace these six actions with one new action that asks me to input a new number. How do I do that?

All you need is the "Prompt for User Input" Action:

"TBD" means To Be Determined".
Replace it with whatever title is meaningful to you.

1 Like

Along with what @JMichaelTX posted (which was great), once you have the value in a variable, there's a couple of ways to have it "typed" by the maco. Assuming the variable name is "MyNumber", you can use one of the following:

  • "Insert Text by Typing" is a little slower, but it doesn't affect the clipboard, and it tends to be more robust.

  • "Insert Text by Pasting" is faster (assuming the application supports having text pasted in), but it changes the value on the clipboard.

By the way, the Prompt that @JMichaelTX showed does not validate for numeric input. If you really need to validate, let us know and we'll show you how. It's not as simple as "flipping a switch", but it can certainly be done if you need it.

DanThomas,

Many thanks. Will either of these create a little pop-up window where I type in the numbers. What JMichaelTX sent brought up a window but there was no place to enter the numbers.

Nfotx

Did you actually test this?

Is there something else you are expecting?

I am performing the most boring task imaginable, seven mouse clicks. But in the middle of those clicks I have to enter the number contained in the name of a pdf file. It has to be inserted into a search field of a window. That results in a document being pulled from a large file. Then more mouse clicks to select the document I brought from the file and have it added to a new pdf file I am working on. If you know about Adobe Acrobat XI, I am "adding a link” from the: crop tool set > Content Editing > More Content > Add or Edit a Link.

In my mind once I trigger the macro the next thing I see is a dialog box asking for the number. I enter the number, KM takes over and adds the link. Then I repeat the process typing in a new number. I don’t know if having KM to type into each time is going to work.

I have 162 of these links to add. That’s why I need a macro.

Thanks

Nfotx

@nfotx, this is a much larger scope that you presented in your OP.
I think we have answered your original question: "How do I get a Macro to ask me for numerical keystrokes?"

But clearly, now, your task is much larger.

To offer you the best help, we need for you to clearly layout all of the manual steps you would use to compete your entire workflow. If you can also attach a sample PDF file, that would be great. Also, a video of you going through these manual steps would be very helpful.

I have Acrobat XI Pro, so I can test it. Much of Acrobat can be automated with either AppleScript, or with JavaScript within Acrobat. Often it is best to take advantage of scripting of apps like Acrobat.

If you will help us understand your workflow, I'm sure we can help you.

1 Like

Attachment available until Feb 6, 2017
JMichaelTX,

I finally got the video file size small enough to attach. This should help you understand what I’m after. I have two variables: (1) the size of the link area that I manually drag and, (2) the document number I have to search before inserting the document into the pdf Report. I would like to manually drag my link area then trigger the macro. It asks me for a file name’s number, I enter it, then move on to the next item on the report.

Thanks so much,

Nfotx

Hey Neil,

No vid. Something misfired...

-Chris

As @ccstone says, there is no attachment to your post.

It is probably better to upload your video somewhere like YouTube, or your DropBox account. Once in DropBox, you can right-click on the file in your Mac Finder, and "Copy Public Link". Then post that link (URL) here.

Gentlemen,

I did not know that one sentence email was even sent. Here is the email that I thought would go through using the OS X Mail large file feature. Obviously it didn’t work. Dropbox link has been provided.

JMichaelTX,

I finally got the video file size small enough to attach. This should help you understand what I’m after. I have two variables: (1) the size of the link area that I manually drag and, (2) the document number I have to search before inserting the document into the pdf Report. I would like to manually drag my link area then trigger the macro. It asks me for a file name’s number, I enter it, then move on to the next item on the report.

Thanks so much,

Nfotx

View Video.