Prompt for User Input > Window Position

I recently started working with the action "Prompt for User Input" which I immediately started to love.

I am using a 30" and a 27" display as a second screen.The window to insert the prompted data seems to appear somewhere on the screen(s). I figured out so far that it remembers the last position but this might be good for one application, but not for another one. Sometimes I find myself searching for it through other open windows.

Since I use the KM window positioning actions quite a lot I figured out that these don't have any affect on this particular one because it is probably not recognized as a "real" window.

Is there a way to position this "Prompt" window per application individually?

Thanks in advance.

This forum discussion

goes some way to answering your question.

I still use the solution mentioned there to ensure the consistent positioning of my prompts.

Hope you find that helpful.

Thanks a lot @tiffle,

this is an interesting approach. I didn't find it for some reason whilst I was searching for solutions.

Unfortunately I can't get it to work. I guess that the limit of my main macro to a specific application does not allow actions in other applications like in this case the KM engine.

I did a test in Apple Mail. I just set a shortcut to a Prompt window and appended the window positioning action as recommended. The window appears but it does not move.

When I run the window positioning from a Global Macro Palette it works. I even tried to call this particular macro from the Global Palette but event this didn't work.

But thanks again anyway!

Can you post your test macro for me to see exactly what you’re doing please? Then when I get back to my Mac I’ll have something to go on. Cheers!

Thanks and of course. Here is a screenshot. The deactivated action was the first try, the macro from the Global group the second. For KM engine I created an alias from within the package as recommended which is located in the application folder.

image

Thanks!

Thanks for that.

  1. Move the Execute Macro "Center Keyboard Maestro..." action to just before the Prompt for User Input action.

  2. Click the gear icon on the Execute Macro action and check the Asynchronously option.

  3. Delete the Set Between Actions Delay action.

  4. Ensure the Center Keyboard Maestro Prompts and Alerts macro looks like this:

KM 0 2021-04-23_23-08-59

  1. You should not create an alias for the KM engine. Read the discussion I linked to previously from post number 5 to the end - that is the relevant information

Here is a segment of one of my macros that uses this technique, just for comparison (it is NOT a rewrite of your macro - just an example):

I hope you can make use of this, but if not let me know and I'll get back to you tomorrow.

Cheers!

2 Likes

Thanks so much @tiffle drawing my attention to these details of the other thread.

Executing the macro asynchronously and putting it before the Prompt obviously did the trick. It seems to work really reliable.

I didn't change something related to the engine alias, it is still there. I even wouldn't know what to select because without the alias I wasn't able to select the engine, just KM as the regular application.

But since it works now it's nothing to worry about I think.

Thanks again and enjoy your weekend. I really appreciate your help!

1 Like

Well as long as it’s working for you is what counts!

Yes, I agree. Thanks again and have a great weekend! :sunglasses:

1 Like

Could you do this in a way that would make the window appear under or near the mouse position that you were at when you started a particular macro?

Never mind, I figured it out. I was overthinking things but grabbing and using the mouse variables worked great once I used this macro and got the syntax right. I love KM so much.

1 Like