dumbeau / AutoHotPie

Radial menus in Windows, aka PIE MENYOOS!
MIT License
304 stars 16 forks source link

Function help #134

Closed Vndless closed 7 months ago

Vndless commented 7 months ago

Hi your project is very cool ! can you add a function ? If I run this, it will paste a predefined text or code

dumbeau commented 7 months ago
  1. Create an AHK script that you can pass arguments into.
  2. Use the "Run File" function and select the ahk script.
  3. Edit the text field by adding your arguments after the file path.

Example:

test.ahk

MsgBox, %1%, %2%
exitapp

image As you can see in the image above, you can reuse the same AHK script on multiple slices, but set different arguments in the "Run File" text field, which is effectively creating your own functions.

I'm happy you find this useful!

dumbeau commented 7 months ago

For your specific request, you can use a script like this:

PasteString.ahk

Send, %1%
exitapp

Just be sure to use quotations so your spaces aren't interpreted as separate arguments.