Aditya Posted March 18, 2010 Share Posted March 18, 2010 My application is minimized to tray & I am trying to use PostMessage to open it. The code in C++ would be:::PostMessage(m_hwndTray, WM_COMMAND, MAKEWPARAM(ID_CLIENT, 0), 0);where ID_CLIENT is ID of the control of our app, which forces the window to open or show. I am trying to do the same in AutoIT & here is my snippet:#include <WinAPI.au3> #include <WindowsConstants.au3> $hWnd = ControlGetHandle('[Class:Shell_TrayWnd]', '', '[Class:ToolbarWindow32;Instance:1]') $ID_CLIENT = 32788 ; this is the ID of the control to which message will be sent. _WinAPI_PostMessage($hWnd, $WM_COMMAND, $ID_CLIENT, 0)) The only problem I have is the MAKEWPARAM macro which gives me the wParam from the ID of the control. How to do this in AutoIT? Link to comment Share on other sites More sharing options...
PsaltyDS Posted March 19, 2010 Share Posted March 19, 2010 where ID_CLIENT is ID of the control of our app...That doesn't sound right for some reason. Where did you get this ID from? Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law Link to comment Share on other sites More sharing options...
Aditya Posted March 19, 2010 Author Share Posted March 19, 2010 That doesn't sound right for some reason. Where did you get this ID from?The devs, its our app. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now