Is there a way to Disable right click or Hide script System Icon if the specific program is still running?

Get help with using AutoHotkey and its commands and hotkeys
ulraf
Posts: 20
Joined: 27 Oct 2019, 10:43
Google: ulra Forums

Is there a way to Disable right click or Hide script System Icon if the specific program is still running?

08 Jul 2020, 10:43

Windows 10.

openFolder.exe (NOT AHK)
1st, I have created a program that opens a specific folder working directory. Username and password will prompt before you can open this directory.

Login.exe (AHK)
2nd, I created a script that will open the program(openfolder.exe) and auto input the Login details.

Is there a way to Disable right click or Hide script System Icon on Login.exe if the openfolder.exe program is still running?

*** My reason for this is my AHK (Login.exe) script also writes/logs for any changes made to this working directory while still active.

Thank you.
Rohwedder
Posts: 3252
Joined: 04 Jun 2014, 08:33
Location: Germany

Re: Is there a way to Disable right click or Hide script System Icon if the specific program is still running?

08 Jul 2020, 13:26

Hallo,
add this in Login.exe:

Code: Select all

Menu, Tray, NoIcon
Process, WaitClose, openFolder.exe
Menu, Tray, Icon
ulraf
Posts: 20
Joined: 27 Oct 2019, 10:43
Google: ulra Forums

Re: Is there a way to Disable right click or Hide script System Icon if the specific program is still running?

09 Jul 2020, 10:58

Rohwedder wrote:
08 Jul 2020, 13:26
Hallo,
add this in Login.exe:

Code: Select all

Menu, Tray, NoIcon
Process, WaitClose, openFolder.exe
Menu, Tray, Icon
Thank You!

Btw, can I disable the right click as well? I'm not really sure for now if Im going to pursue hiding of the script Icon since it is the easiest way to know if my script is running :D
Rohwedder
Posts: 3252
Joined: 04 Jun 2014, 08:33
Location: Germany

Re: Is there a way to Disable right click or Hide script System Icon if the specific program is still running?

10 Jul 2020, 02:21

Then:

Code: Select all

; Menu, Tray, NoIcon
Process, WaitClose, openFolder.exe
Menu, Tray, Icon
Hotkey, *RButton, Off
Return
*RButton::Return
To hide script System Icon activate Menu, Tray, NoIcon.
BoBo
Posts: 3299
Joined: 13 May 2014, 17:15

Re: Is there a way to Disable right click or Hide script System Icon if the specific program is still running?

10 Jul 2020, 02:43

since it is the easiest way to know if my script is running
F1 & F12::MsgBox % "I'm still running Master!" :?:
ulraf
Posts: 20
Joined: 27 Oct 2019, 10:43
Google: ulra Forums

Re: Is there a way to Disable right click or Hide script System Icon if the specific program is still running?

11 Jul 2020, 12:28

Rohwedder wrote:
10 Jul 2020, 02:21
Then:

Code: Select all

; Menu, Tray, NoIcon
Process, WaitClose, openFolder.exe
Menu, Tray, Icon
Hotkey, *RButton, Off
Return
*RButton::Return
To hide script System Icon activate Menu, Tray, NoIcon.
I mean disable the right click of the running script icon that is found in the tray. Sorry for the confusion. Thanks

Return to “Ask For Help”

Who is online

Users browsing this forum: doubledave22, JaydeNpie, Jovannb, jvlz, kevlea and 43 guests