Jump to content

shaktiku1

Members
  • Posts

    9
  • Joined

  • Last visited

Everything posted by shaktiku1

  1. Thanks for your reply.It solved my problem. BTW ComboBox1 is Edit1 (please consider as typo error)
  2. Thank you for the reply, I have to send more texts in the file.
  3. Hi, I have written a single script(to work on different OS/different language) to open run Notepad ,send some keys and close and save to some location. Below is the code:- Run("notepad.exe") $handle = WinWaitActive("[CLASS:Notepad]","") WinSetState("[CLASS:Notepad]","",@SW_MAXIMIZE) Send("Hello there") WinClose($handle) $handle = WinGetHandle("[ACTIVE]") ControlClick($handle,"","[CLASS:Button; INSTANCE:1]") $handle = WinWaitActive("[CLASS:#32770]","") $hw = WinGetHandle("[ACTIVE]") ControlSetText($hw, "", "ComboBox1", "c:\actual") ControlSend($hw,"","ComboBox3","UTF-8") ControlClick($hw,"","[CLASS:Button; INSTANCE:1]") When i run the above script 2 out of 5 times it fails. I don't know whats wrong with this code.Most of the time it stops at SaveAs window where i am sending path to save the notepad. Can you please review the code and help me . Thanks!!
  4. Hi , I am writing script to work on multiple languages (like French, German) Below is my script to open notepad, I used CLASS in Title parameter so that it works across different OS platforms. Run("notepad.exe") WinWaitActive("[CLASS:Notepad]","") WinSetState("[CLASS:Notepad]","",@SW_MAXIMIZE) Send("Hello there") $handle = WinGetHandle("[CLASS:Notepad]") WinClose($handle) ControlClick($handle,"","[CLASS:Button; INSTANCE:1]") // Not Working But i am unable to click on Save button as show in screenhsot '> Can you please help in resolving this issue.. Thanks !!
  5. Hi, I am working on to send Keyboard keys to notepad opened in Win7 m/c(which i am accessing using webBrowser{called as console view} just like client-server) which is in maximized mode and focus is set to notepad. I have created AutoIT script to get the handle of the browser's window but when i triggers AutoIT script through batch script it is not recognizing properly ,though its find the browser window properly but not sending the keys to notepad I am attaching the screenshot of the opened Win7 m/c for reference(https://dl.dropboxusercontent.com/u/91420517/Insession.JPG) **If i run the AutoIT script and click inside the opened notepad,then sendkeys sends all the key properly. $hFirefox = WinGetHandle("[CLASS:MozillaWindowClass; TITLE:FRwin7x64 - Mozilla Firefox]", "") WinActivate($hFirefox,"") ; Character in Small letters ;-------------------------- Sleep(1000) Send("a") send("{ENTER}") Send("b") send("{ENTER}") Send("c") send("{ENTER}") Send("d") send("{ENTER}") Send("e") send("{ENTER}") AutoIT Window Info >>>> Window <<<< Title: FRwin7x64 - Mozilla Firefox Class: MozillaWindowClass Position: 594, 46 Size: 836, 718 Style: 0x16CF0000 ExStyle: 0x00000100 Handle: 0x00040018 >>>> Control <<<< Class: Instance: ClassnameNN: Name: Advanced (Class): ID: Text: Position: Size: ControlClick Coords: Style: ExStyle: Handle: >>>> Mouse <<<< Position: 953, 174 Cursor ID: 0 Color: 0x0959AE >>>> StatusBar <<<< >>>> ToolsBar <<<< >>>> Visible Text <<<< >>>> Hidden Text <<<< Please help in resolving this way or let me know the better way of finding the windows control. *Sorry if i not very clear is describing my issue.. Many Thanks in advance!!
  6. Thank you Exit very much, it worked and yes it worked only with German keyboard only. So final conclusion is to use { } brackets send("{CTRLDOWN}{ALTDOWN}{+}{CTRLUP}{ALTUP}") or Send("!^{+}") Regards, Shakti
  7. thanks Palestinian for the link. I am doing in the same way , but when autoit executes the line send("{CTRLDOWN}{ALTDOWN}+{CTRLUP}{ALTUP}") it doesn't print anything.
  8. Hi , I am working to simulate/automate German keyboard(keyboad layout for reference) keys using Autoit. To print char ~ , we need to press ALTGr key and + sign . To send this i am using below command send("{CTRLDOWN}{ALTDOWN}ß{CTRLUP}{ALTUP}") ; to send send("{ENTER}") send("{CTRLDOWN}{ALTDOWN}+{CTRLUP}{ALTUP}") ; buggy line NOT Working - to send ~ send("{ENTER}") send("{CTRLDOWN}{ALTDOWN}q{CTRLUP}{ALTUP}") ; to send @ Can you please help me how to send + using this command , i tried escape char but not working. Or is there any other way to send ATLGr keys Thanks in Advance!!
×
×
  • Create New...