iCrypto Posted September 11, 2016 Posted September 11, 2016 Hello, im trying to automate the TMCL-IDE, its a Step Motor Development Program. I want to click 3 Buttons, later I will post the infos I got by AutoIT Window info Tool Here a Screenshot: Here are the Infos of the Buttons: First one: Play Script Spoiler >>>> Window <<<< Title: TMCL Integrated Development Environment - [New File 1] Class: TFEditor Position: 175, 168 Size: 1077, 993 Style: 0x16CF0000 ExStyle: 0x00010100 Handle: 0x00070428 >>>> Control <<<< Class: TToolBar Instance: 1 ClassnameNN: TToolBar1 Name: Advanced (Class): [CLASS:TToolBar; INSTANCE:1] ID: 525372 Text: Position: 0, 0 Size: 1061, 31 ControlClick Coords: 197, 15 Style: 0x5600884E ExStyle: 0x00010000 Handle: 0x0008043C >>>> Mouse <<<< Position: 380, 233 Cursor ID: 0 Color: 0x000000 >>>> StatusBar <<<< >>>> ToolsBar <<<< >>>> Visible Text <<<< [New File 1] >>>> Hidden Text <<<< Button 2: Stop Spoiler >>>> Window <<<< Title: TMCL Integrated Development Environment - [New File 1] Class: TFEditor Position: 175, 168 Size: 1077, 993 Style: 0x16CF0000 ExStyle: 0x00010100 Handle: 0x00070428 >>>> Control <<<< Class: TToolBar Instance: 1 ClassnameNN: TToolBar1 Name: Advanced (Class): [CLASS:TToolBar; INSTANCE:1] ID: 525372 Text: Position: 0, 0 Size: 1061, 31 ControlClick Coords: 220, 15 Style: 0x5600884E ExStyle: 0x00010000 Handle: 0x0008043C >>>> Mouse <<<< Position: 403, 233 Cursor ID: 0 Color: 0x000000 Button 3: Continue Spoiler >>>> Window <<<< Title: TMCL Integrated Development Environment - [New File 1] Class: TFEditor Position: 175, 168 Size: 1077, 993 Style: 0x16CF0000 ExStyle: 0x00010100 Handle: 0x00070428 >>>> Control <<<< Class: TToolBar Instance: 1 ClassnameNN: TToolBar1 Name: Advanced (Class): [CLASS:TToolBar; INSTANCE:1] ID: 525372 Text: Position: 0, 0 Size: 1061, 31 ControlClick Coords: 242, 15 Style: 0x5600884E ExStyle: 0x00010000 Handle: 0x0008043C >>>> Mouse <<<< Position: 425, 233 Cursor ID: 0 Color: 0x000000 >>>> StatusBar <<<< >>>> ToolsBar <<<< >>>> Visible Text <<<< [New File 1] >>>> Hidden Text <<<<
iCrypto Posted September 11, 2016 Author Posted September 11, 2016 3 minutes ago, AutoBert said: Read in Helpfile about ControlCommand. Reading it, so I understood this: ControlCommand($hWnd,""," [CLASS:TToolBar; INSTANCE:1]","dontknow") What is the last Parameter? I didnt really understand it, I think you send a command to the Program, but how can I know what Function is getting executed when you press the play button??
AutoBert Posted September 11, 2016 Posted September 11, 2016 Try this: ControlCommand($hWnd,""," [CLASS:TToolBar; INSTANCE:1]","SendCommandID","1") ; test with 0 to no of Toolbarbuttons instead of 1 I am downloading the TCML-IDE, after last race of MotoGP is finished, i will have a look myself. Da du aber auch im dt. Forum ein Thema eröffnest hast werde ich dann dort antworten.
genius257 Posted September 15, 2016 Posted September 15, 2016 I know it's not the best, but: ControlClick($hWnd, "", "[CLASS:TToolBar; INSTANCE:1]", "left", 1, 380, 233); Play Script ControlClick($hWnd, "", "[CLASS:TToolBar; INSTANCE:1]", "left", 1, 220, 15); Stop ControlClick($hWnd, "", "[CLASS:TToolBar; INSTANCE:1]", "left", 1, 242, 15); Continue I don't know if your mouse position matches the controls you want to click, so you might want to re-check those before run. To show your appreciation My highlighted topics: AutoIt Package Manager, AutoItObject Pure AutoIt, AutoIt extension for Visual Studio Code Github: AutoIt HTTP Server, AutoIt HTML Parser
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