AutoHotkey Community

It is currently May 26th, 2012, 5:34 pm

All times are UTC [ DST ]




Post new topic Reply to topic  [ 12 posts ] 
Author Message
 Post subject: WMP Controls in MiniMode
PostPosted: January 25th, 2008, 1:16 pm 
Offline

Joined: January 7th, 2008, 3:03 pm
Posts: 9
Hello,
I have WMP 11 on Win XP SP2. I am trying to just get the pause and play features to work when WMP is in MiniMode. I have seen numerous posts about this but I have not gotten any of them to work. I know it can be done because I have seen some other hotkey tools accomplish this as well.

When trying some of the posted examples I have usually just pasted this into my autohotkey.ahk default file (though separate files have not worked for me either). This has been driving me nuts as I know this has to be possible but I can't seem to get it to work.

Thanks for any help!


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: January 25th, 2008, 2:28 pm 
Offline

Joined: May 17th, 2007, 4:49 pm
Posts: 38
!a::Send {Media_Next}
!s::Send {Media_Prev}
!d::Send {Media_Stop}
!f::Send {Media_Play_Pause}

?


Report this post
Top
 Profile  
Reply with quote  
 Post subject: Still no luck
PostPosted: January 25th, 2008, 3:51 pm 
Offline

Joined: January 7th, 2008, 3:03 pm
Posts: 9
This only sort of works when WMP is not minimized (opens a right menu type dialog box but does pause and restart). However the commands do nothing when WMP is in mini mode

Thanks!


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: April 20th, 2009, 7:33 pm 
Quote:
~a::
Send, {vkB3sc122}
return

Works for me in mini-mode


Report this post
Top
  
Reply with quote  
 Post subject:
PostPosted: April 21st, 2009, 3:44 am 
Offline

Joined: April 17th, 2009, 9:02 am
Posts: 20
"PostMessage / SendMessage" command can make it ;)

Code:
;WinKey+Down to "Play/Pause"
#Down::  SendMessage, 0x111, 18808, , , ahk_class WMPlayerApp
;WinKey+Up to "Stop"
#Up::    SendMessage, 0x111, 18809, , , ahk_class WMPlayerApp
;WinKey+Left to "Previous Song"
#Left::  SendMessage, 0x111, 18810, , , ahk_class WMPlayerApp
;WinKey+Right to "Next Song"
#Right:: SendMessage, 0x111, 18811, , , ahk_class WMPlayerApp


Report this post
Top
 Profile  
Reply with quote  
 Post subject: WMP Keys
PostPosted: April 21st, 2009, 7:34 am 
Offline

Joined: January 7th, 2008, 3:03 pm
Posts: 9
I had settled on the following which works quite well:

#PgDn::Send {Media_Next}
#PgUp::Send {Media_Prev}
`::Send {Media_Play_Pause}

Interestingly, while the above work, the volume controls I tried below do not:

#up::Send {Media_Volume_Up}
#down::Send {Media_Volume_Down}

But that's relatively minor in the scheme of things.

Danny


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: April 21st, 2009, 7:46 am 
Offline

Joined: April 17th, 2009, 9:02 am
Posts: 20
Code:
;WinKey+Down to "Play/Pause"
#Down::  SendMessage, 0x111, 18808, , , ahk_class WMPlayerApp
;WinKey+Up to "Stop"
#Up::    SendMessage, 0x111, 18809, , , ahk_class WMPlayerApp
;WinKey+Left to "Previous Song"
#Left::  SendMessage, 0x111, 18810, , , ahk_class WMPlayerApp
;WinKey+Right to "Next Song"
#Right:: SendMessage, 0x111, 18811, , , ahk_class WMPlayerApp

;WinKey+PgUp to "Volume Up"
#PgUp:: SendMessage, 0x111, 18815, , , ahk_class WMPlayerApp
;WinKey+PgDn to "Volume Down"
#PgDn:: SendMessage, 0x111, 18816, , , ahk_class WMPlayerApp
;WinKey+End to "Mute/Unmute"
#End:: SendMessage, 0x111, 18817, , , ahk_class WMPlayerApp


Main features of "PostMessage / SendMessage" is can send command in background, which mean works with minimode too, even u winhide the window media player, it still work as charm~ ;)


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: April 21st, 2009, 8:13 am 
Offline

Joined: January 7th, 2008, 3:03 pm
Posts: 9
I tested these for fun and none of them work for me when WMP is in Mini Mode. They work fine when it is maximized or minimized. The commands I listed work in all situations I have tried so far--except the volume controls.

Danny


Report this post
Top
 Profile  
Reply with quote  
 Post subject: Re: WMP Keys
PostPosted: April 21st, 2009, 2:09 pm 
Offline

Joined: October 17th, 2006, 4:15 pm
Posts: 7502
Location: Australia
danwdoo wrote:
Interestingly, while the above work, the volume controls I tried below do not:
Media_Volume_Up and Media_Volume_Down usually control Windows' master volume, not Windows Media Player. :)
yunhen3350 wrote:
Main features of "PostMessage / SendMessage" is can send command in background,
...but it can only send to hidden windows if you first use:
Code:
DetectHiddenWindows, On


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: April 22nd, 2009, 3:28 am 
Offline

Joined: January 7th, 2008, 3:03 pm
Posts: 9
Is there a particular place to put the "DetectHiddenWindows, On". I tried just placing it in my default autohotkey.ahk above the WMP commands but it did not have any effect. The controls still will not work in mini-mode. Perhaps I'm using it wrong somehow?

Thanks for all your help on this!
Danny


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: April 22nd, 2009, 5:08 am 
Offline

Joined: April 17th, 2009, 9:02 am
Posts: 20
Quote:
Is there a particular place to put the "DetectHiddenWindows, On".

Place it on script starting initial part as where
Code:
#NoEnv  ; Recommended for performance and compatibility with future AutoHotkey releases.
SendMode Input  ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir%  ; Ensures a consistent starting directory.
DetectHiddenWindows, On ;here


Quote:
...but it can only send to hidden windows if you first use:

Oops, sorry for my mistake. thanks for remind, Lexikos


I'd experienced that the "lParam" for "PostMessage / SendMessage" commands may various from every PC.
In that case u'll need to capture the "lParam" from "Winspector" software.

I'd tried mine, functional at toolbar mode too, but not at skin mode


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: April 22nd, 2009, 10:46 am 
Offline

Joined: January 7th, 2008, 3:03 pm
Posts: 9
Tested again with these additions put at the top of the script (mine did not have any of them) and now it works with the new commands--including volume!

Thanks a bunch!
Danny


Report this post
Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 12 posts ] 

All times are UTC [ DST ]


Who is online

Users browsing this forum: batto, BrandonHotkey, mrhobbeys, MSN [Bot], Mtes, notsoobvious, rbrtryn, stanman and 63 guests


You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Group