Klexen Posted July 19, 2007 Share Posted July 19, 2007 I use this first script to get the pos and write it to ini. Then I run second script to set the size. WinGetPos("klexen-laptop - Remote Desktop") iniwrite("test.ini","Size","Size1",$size[0]) iniwrite("test.ini","Size","Size2",$size[1]) iniwrite("test.ini","Size","Size3",$size[2]) iniwrite("test.ini","Size","Size4",$size[3])oÝ÷ Ù«¢+ØÀÌØíÍ¥éÄô¥¹¥É ÅÕ½ÐíÑÍй¥¹¤ÅÕ½Ðì°ÅÕ½ÐíM¥éÅÕ½Ðì°ÅÕ½ÐíM¥éÄÅÕ½Ðì°ÅÕ½ÐìÅÕ½Ðì¤(ÀÌØíÍ¥éÈô¥¹¥É ÅÕ½ÐíÑÍй¥¹¤ÅÕ½Ðì°ÅÕ½ÐíM¥éÅÕ½Ðì°ÅÕ½ÐíM¥éÈÅÕ½Ðì°ÅÕ½ÐìÅÕ½Ðì¤(ÀÌØíÍ¥éÌô¥¹¥É ÅÕ½ÐíÑÍй¥¹¤ÅÕ½Ðì°ÅÕ½ÐíM¥éÅÕ½Ðì°ÅÕ½ÐíM¥éÌÅÕ½Ðì°ÅÕ½ÐìÅÕ½Ðì¤(ÀÌØíÍ¥éÐô¥¹¥É ÅÕ½ÐíÑÍй¥¹¤ÅÕ½Ðì°ÅÕ½ÐíM¥éÅÕ½Ðì°ÅÕ½ÐíM¥éÐÅÕ½Ðì°ÅÕ½ÐìÅÕ½Ðì¤()]¥¹5½Ù ÅÕ½Ðí±á¸µ±ÁѽÀ´Iµ½ÑÍѽÀÅÕ½Ðì°ÅÕ½ÐìÅÕ½Ðì°ÀÌØíÍ¥éÄ°ÀÌØíÍ¥éÈ°ÀÌØíÍ¥éÌ°ÀÌØíÍ¥éФ Link to comment Share on other sites More sharing options...
Emperor Posted July 19, 2007 Share Posted July 19, 2007 Why not just get the size and then use WinMove() in the same script? $Size = WinGetPos("klexen-laptop - Remote Desktop") WinMove("klexen-laptop - Remote Desktop", "", $Size[0], $Size[1], $Size[2], $Size[3]) Link to comment Share on other sites More sharing options...
Klexen Posted July 19, 2007 Author Share Posted July 19, 2007 Why not just get the size and then use WinMove() in the same script? $Size = WinGetPos("klexen-laptop - Remote Desktop") WinMove("klexen-laptop - Remote Desktop", "", $Size[0], $Size[1], $Size[2], $Size[3]) Wouldnt it just cause it to do nothing? The program would get current location of window, then move it to same location right? Link to comment Share on other sites More sharing options...
Emperor Posted July 19, 2007 Share Posted July 19, 2007 Wouldnt it just cause it to do nothing? The program would get current location of window, then move it to same location right?Yes it would, but isn't that what you're doing in your scripts? Unless you plan to save the windows location and move it back there later then your scripts are fine. Link to comment Share on other sites More sharing options...
Klexen Posted July 19, 2007 Author Share Posted July 19, 2007 Yes it would, but isn't that what you're doing in your scripts? Unless you plan to save the windows location and move it back there later then your scripts are fine.Yeah that was the plan, When I login and recreate the window I want it to size it to what I had it before. Link to comment Share on other sites More sharing options...
PsaltyDS Posted July 19, 2007 Share Posted July 19, 2007 I use this first script to get the pos and write it to ini. Then I run second script to set the size. WinGetPos("klexen-laptop - Remote Desktop") iniwrite("test.ini","Size","Size1",$size[0]) iniwrite("test.ini","Size","Size2",$size[1]) iniwrite("test.ini","Size","Size3",$size[2]) iniwrite("test.ini","Size","Size4",$size[3])oÝ÷ Ù«¢+ØÀÌØíÍ¥éÄô¥¹¥É ÅÕ½ÐíÑÍй¥¹¤ÅÕ½Ðì°ÅÕ½ÐíM¥éÅÕ½Ðì°ÅÕ½ÐíM¥éÄÅÕ½Ðì°ÅÕ½ÐìÅÕ½Ðì¤(ÀÌØíÍ¥éÈô¥¹¥É ÅÕ½ÐíÑÍй¥¹¤ÅÕ½Ðì°ÅÕ½ÐíM¥éÅÕ½Ðì°ÅÕ½ÐíM¥éÈÅÕ½Ðì°ÅÕ½ÐìÅÕ½Ðì¤(ÀÌØíÍ¥éÌô¥¹¥É ÅÕ½ÐíÑÍй¥¹¤ÅÕ½Ðì°ÅÕ½ÐíM¥éÅÕ½Ðì°ÅÕ½ÐíM¥éÌÅÕ½Ðì°ÅÕ½ÐìÅÕ½Ðì¤(ÀÌØíÍ¥éÐô¥¹¥É ÅÕ½ÐíÑÍй¥¹¤ÅÕ½Ðì°ÅÕ½ÐíM¥éÅÕ½Ðì°ÅÕ½ÐíM¥éÐÅÕ½Ðì°ÅÕ½ÐìÅÕ½Ðì¤()]¥¹5½Ù ÅÕ½Ðí±á¸µ±ÁѽÀ´Iµ½ÑÍѽÀÅÕ½Ðì°ÅÕ½ÐìÅÕ½Ðì°ÀÌØíÍ¥éÄ°ÀÌØíÍ¥éÈ°ÀÌØíÍ¥éÌ°ÀÌØíÍ¥éФoÝ÷ Ûú®¢×½éì'$z»h¦ëb¶)íêÞ+-¯&®¶sd÷D¶W6WBgV÷C·´U47ÒgV÷C²ÂgV÷CµõVBgV÷C²¤÷D¶W6WBgV÷C¶ÒgV÷C²ÂgV÷CµôÖ÷fTBgV÷C² ¥'VâgV÷C¶æ÷FWBæWRgV÷C²¥våvD7FfRgV÷CµVçFFÆVBÒæ÷FWBgV÷C²¢b33c·6¦RÒvävWE÷2gV÷CµVçFFÆVBÒæ÷FWBgV÷C² ¤f÷"b33c¶âÒFò0 &Vuw&FRgV÷C´´5Rb3#µ4ôeEt$Rb3#µôÖ÷fTBgV÷C²ÂgV÷Cµ6¦RgV÷C²fײb33c¶âÂgV÷Cµ$TuôEtõ$BgV÷C²Âb33c·6¦U²b33c¶åÒ¤æW@ ¥vÆR G&FgV÷C´Ö÷fTBgV÷C²ÂgV÷C´Bb33¶Òb33²FòÖ÷fRFRæ÷FWBvæF÷r&6²âgV÷C²ÂR 6ÆVW¥tVæ@ ¤gVæ2ôÖ÷fTB f÷"b33c¶âÒFò0 b33c·6¦U²b33c¶åÒÒ&Vu&VBgV÷C´´5Rb3#µ4ôeEt$Rb3#µôÖ÷fTBgV÷C²ÂgV÷Cµ6¦RgV÷C²fײb33c¶â æW@ väÖ÷fRgV÷CµVçFFÆVBÒæ÷FWBgV÷C²ÂgV÷C²gV÷C²Âb33c·6¦U³ÒÂb33c·6¦U³ÒÂb33c·6¦U³%ÒÂb33c·6¦U³5Ò¤VæDgVæ2³ÓÒfwCµôÖ÷fT@ ¤gVæ2õVB W@¤VæDgVæ2³ÓÒfwCµõV@ 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...
Klexen Posted July 19, 2007 Author Share Posted July 19, 2007 Pretty slick there buddy! ... Now tell me how to make it work on this kind of window. This is a citrix program I use at work. The program uses RDP for the connection, but the RDP session is inside a wierd window. That win move has no effect on. Winactive works on the title though. >>>> Window <<<< Title: IDD - \\Remote Class: Transparent Windows Client Position: 62, 1 Size: 1014, 79 Style: 0x960F0000 ExStyle: 0x00050104 >>>> Control <<<< Class: Instance: ID: Text: Position: Size: ControlClick Coords: Style: ExStyle: >>>> Mouse <<<< Position: 110, 12 Cursor ID: 0 Color: 0x000080 >>>> StatusBar <<<< >>>> Visible Text <<<< >>>> Hidden Text <<<< Link to comment Share on other sites More sharing options...
PsaltyDS Posted July 20, 2007 Share Posted July 20, 2007 (edited) AutoIt is not magic. It makes calls to standard Windows API/COM/DLL objects. So apps, like Citrix Metaframe and ColdFusion/Flash, draw their own windows with their own internal functions that don't use the standard Windows controls. You may be just plain out of luck. Edit: Typo. Edited July 20, 2007 by PsaltyDS 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...
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