Running volume mixer

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
Qwerty-Space
Posts: 5
Joined: 11 Jan 2016, 22:34

Running volume mixer

Post by Qwerty-Space » 11 Jan 2016, 22:37

Hello!

I'm trying to run volume mixer with the command Win+V and place it just above the tray/clock area like it would when you open it normally. So far what I've got opens it to the default position of the left hand side of the screen.

Code: Select all

; Volume Mixer

#v::Run C:\Windows\System32\SndVol.exe
if WinExist("ahk_exe SndVol.exe")
    WinActivate, ahk_exe SndVol.exe
WinMove, ahk_exe SndVol.exe, 1620, 1000
How can I get this to work? Thanks.

User avatar
jmeneses
Posts: 524
Joined: 28 Oct 2014, 11:09
Location: Catalan Republic

Re: Running volume mixer

Post by jmeneses » 12 Jan 2016, 09:06

Hi Qwerty-Space and welcome to the forum

This execute only the run Command

Code: Select all

#v::Run C:\Windows\System32\SndVol.exe 
....
.......
........
Try this

Code: Select all

#v::
Run C:\Windows\System32\SndVol.exe
WinWait, ahk_exe SndVol.exe
If WinExist("ahk_exe SndVol.exe")  
    WinActivate, ahk_exe SndVol.exe
WinMove, ahk_exe SndVol.exe,, 1620, 1000                 ;     <<-- NOTE need another "," 
Return
Donec Perficiam

Qwerty-Space
Posts: 5
Joined: 11 Jan 2016, 22:34

Re: Running volume mixer

Post by Qwerty-Space » 12 Jan 2016, 13:38

Thanks! Worked like a charm!

s1rrah
Posts: 5
Joined: 26 Jun 2022, 06:49

Re: Running volume mixer

Post by s1rrah » 26 Jun 2022, 06:54

Hi ... here I am to revive this awesome thread ... ;-) ... thank you so much for the script on how to show the volume mixer; it is working well for me.

How would I go about changing the script so that when I used the hotkey again, it would then *hide* the volume mixer?

I use a similar script to show/hide desktop icons and it is mapped to WIN-F9 ... if I hit WIN-F9 then the icons will be hidden and if I hit WIN-F9 again, they will then re appear.

Could I do something similar with the show volume mixer script?

Here is the code that I use to show/hide desktop icons (Win 11):

Code: Select all

F10::

ControlGet, HWND, Hwnd,, SysListView321, ahk_class Progman
If HWND =
ControlGet, HWND, Hwnd,, SysListView321, ahk_class WorkerW
If DllCall("IsWindowVisible", UInt, HWND)
WinHide, ahk_id %HWND%
Else
WinShow, ahk_id %HWND%

Return
Thanks for any tips...


[Mod edit: Changed quote tags to code tags]

Post Reply

Return to “Ask for Help (v1)”