Sunblood Posted April 4, 2013 Share Posted April 4, 2013 (edited) I'm using a program that will automatically hide itself and create a tray icon when it is minimized. However, the AutoIt way of minimization does not seem to activate this function for the program - it simply minimizes down to the task bar like any normal program would do. Outside of directly sending keystrokes, how can I emulate an actual "minimize" button press for this program? ControlSend (and similar Control functions) are acceptable. EDIT: More info: The program is MME Audio Repeater from Virtual Audio Cable, for anyone wondering. I can't just @SW_HIDE the program as it only creates the tray icon if it's minimized properly Edited April 4, 2013 by Sunblood Link to comment Share on other sites More sharing options...
MuchTex Posted April 4, 2013 Share Posted April 4, 2013 I'm not 100% sure what you are asking. If you are just trying to minimize your AutoIt GUI then: GUISetState(@SW_MINIMIZE) If you are trying to minimize a different GUI then try using the AutoIt Window Info to get the exact title. Link to comment Share on other sites More sharing options...
PhoenixXL Posted April 4, 2013 Share Posted April 4, 2013 When you press the Minimize button a trayicon is created but when you set the state of the program using WinSetState( $sTitle, $sText, @SW_MINIMIZE ) you don't get the trayicon. If yes, then something under the hood is going on. You could just simulate the Clicking process on the Minimize button, I guess My code: PredictText: Predict Text of an Edit Control Like Scite. Remote Gmail: Execute your Scripts through Gmail. StringRegExp:Share and learn RegExp.Run As System: A command line wrapper around PSEXEC.exe to execute your apps scripts as System (LSA). Database: An easier approach for _SQ_LITE beginners. MathsEx: A UDF for Fractions and LCM, GCF/HCF. FloatingText: An UDF for make your text floating. Clipboard Extendor: A clipboard monitoring tool. Custom ScrollBar: Scroll Bar made with GDI+, user can use bitmaps instead. RestrictEdit_SRE: Restrict text in an Edit Control through a Regular Expression. Link to comment Share on other sites More sharing options...
Sunblood Posted April 4, 2013 Author Share Posted April 4, 2013 When you press the Minimize button a trayicon is created but when you set the state of the program using WinSetState( $sTitle, $sText, @SW_MINIMIZE ) you don't get the trayicon.If yes, then something under the hood is going on. You could just simulate the Clicking process on the Minimize button, I guessYeah that's the exact problem.I could do it with mouseclicks but I'm looking for something more elegant to be able to automate the process without taking the active window. Link to comment Share on other sites More sharing options...
PhoenixXL Posted April 4, 2013 Share Posted April 4, 2013 So is it the real minimize button like we have in a normal GUICreate or does it look somewhat other than that ? My code: PredictText: Predict Text of an Edit Control Like Scite. Remote Gmail: Execute your Scripts through Gmail. StringRegExp:Share and learn RegExp.Run As System: A command line wrapper around PSEXEC.exe to execute your apps scripts as System (LSA). Database: An easier approach for _SQ_LITE beginners. MathsEx: A UDF for Fractions and LCM, GCF/HCF. FloatingText: An UDF for make your text floating. Clipboard Extendor: A clipboard monitoring tool. Custom ScrollBar: Scroll Bar made with GDI+, user can use bitmaps instead. RestrictEdit_SRE: Restrict text in an Edit Control through a Regular Expression. Link to comment Share on other sites More sharing options...
Sunblood Posted April 5, 2013 Author Share Posted April 5, 2013 I'll attach a picture of the program. I want to emphasize this is NOT an AutoIt created GUI, it is an external program not made by me. Link to comment Share on other sites More sharing options...
PhoenixXL Posted April 6, 2013 Share Posted April 6, 2013 The NC Area doesn't seems to be of WindowsAPI, its user drawn control which is used to set the state of the window.Have you tried Autoit Window Info Tool over that minimize button ? My code: PredictText: Predict Text of an Edit Control Like Scite. Remote Gmail: Execute your Scripts through Gmail. StringRegExp:Share and learn RegExp.Run As System: A command line wrapper around PSEXEC.exe to execute your apps scripts as System (LSA). Database: An easier approach for _SQ_LITE beginners. MathsEx: A UDF for Fractions and LCM, GCF/HCF. FloatingText: An UDF for make your text floating. Clipboard Extendor: A clipboard monitoring tool. Custom ScrollBar: Scroll Bar made with GDI+, user can use bitmaps instead. RestrictEdit_SRE: Restrict text in an Edit Control through a Regular Expression. Link to comment Share on other sites More sharing options...
Rickname Posted April 6, 2013 Share Posted April 6, 2013 (edited) You didn't explain well to understand what you want to do. Do you want to get your GUI minimized because the program is not getting minimized when you're running this code ?: Opt("WinTitleMatchMode", 2) WinSetState("Audio Repeater","",@SW_MINIMIZE) Edited April 6, 2013 by Rickname 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