2

I want to launch my AHK script like described here. I will need to do two different things, A and B. I can either put them in one script, or two separate scripts. But B needs some data from A, which is where my problem lies.

  • Solution one: Put A and B into one script, and somehow notify it when it's time for part B, but without restarting it. But how?
  • Solution two: Put them into separate scripts, and somehow pass the values between them. But again, how? The value does not fit into the exit code, and I also don't know how to get the exit code and now to launch multiple executables from and UWP app.
mklement0
  • 382,024
  • 64
  • 607
  • 775
JonnyLee
  • 85
  • 7
  • Have you considered having the first script write to a text file and then having the next script read from that file? [Write](https://autohotkey.com/docs/commands/FileAppend.htm) and [Read](https://autohotkey.com/docs/commands/FileReadLine.htm) are not too difficult to implement. – techturtle Nov 19 '18 at 16:37
  • AHK can also do `RegWrite` and `RegRead` as well as `IniWrite` and `IniRead` to pass info. With cloud sync and using `A_ComputerName` and/or `A_UserName` in the ini file name, you can pass pc- or user-specific info between AHK scripts. – PGilm Nov 19 '18 at 18:50

0 Answers0