Shonnie Posted July 1, 2007 Share Posted July 1, 2007 (edited) Opt("MouseCoordMode",0) $size = WinGetClientSize("Program Manager") $x = $size[0] / -4 $y = $size[1] / 6 MouseMove(5, 5) MouseDown("left") MouseMove($x, $y, 30) MouseUp("left") What its supposed to do: Move a 800x600 window down to the bottom right corner of the screen (independant of resolution) What it does: Exactly what it should when screen res is 1280 x 1024. Way out of whack with any other res Edit: Was thinking make seperate moving codes for each resoluation then detecting screen res and moving the 800x600 window depending... Edit 2: X is independant, because the window can just be dragged until the mouse stops moving =) Edited July 1, 2007 by Shonnie Link to comment Share on other sites More sharing options...
martin Posted July 1, 2007 Share Posted July 1, 2007 Opt("MouseCoordMode",0) $size = WinGetClientSize("Program Manager") $x = $size[0] / -4 $y = $size[1] / 6 MouseMove(5, 5) MouseDown("left") MouseMove($x, $y, 30) MouseUp("left") What its supposed to do: Move a 800x600 window down to the bottom right corner of the screen (independant of resolution) What it does: Exactly what it should when screen res is 1280 x 1024. Way out of whack with any other res Edit: Was thinking make seperate moving codes for each resoluation then detecting screen res and moving the 800x600 window depending... Edit 2: X is independant, because the window can just be dragged until the mouse stops moving =) I assume the mouseDown("left") is to grab the title bar of a window. Instead of WInGetClientSize for "Program Manager" you can use @DeskTopHeight and @DeskTopWidth. Is there some reason you can't use WinMove? Also, might be worth making sure you moves are integers using $x = Int(...) etc Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script. Link to comment Share on other sites More sharing options...
Shonnie Posted July 1, 2007 Author Share Posted July 1, 2007 >< im such a noob... jeeze. thank for the help its workin now. another question though... MY FUNCTIONS STOPPED WORKING !!! i mean... if i put Check() at the beginning of my script it works FINE but if i go... Start() Func Start() If $this = 1 Then Check() EndIf EndFunc wont work for me... i r sad Link to comment Share on other sites More sharing options...
martin Posted July 1, 2007 Share Posted July 1, 2007 >< im such a noob... jeeze. thank for the help its workin now. another question though... MY FUNCTIONS STOPPED WORKING !!! i mean... if i put Check() at the beginning of my script it works FINE but if i go... Start() Func Start() If $this = 1 Then Check() EndIf EndFunc wont work for me... i r sad You haven't given quite enough information, but if Check() works then $this must not be 1. Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script. Link to comment Share on other sites More sharing options...
Shonnie Posted July 2, 2007 Author Share Posted July 2, 2007 (edited) Yeah I just rewrote the entire program so no worries =D AutoIt gets tougher at 1200 lines Any way to make sure my GUI wont get resized? Edit: Check() didnt work because I was surpressing user input... thats the only thing i can think of =0 Edited July 2, 2007 by Shonnie Link to comment Share on other sites More sharing options...
Raffle Posted July 2, 2007 Share Posted July 2, 2007 what are you making that's 1200 lines o.O 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