Jump to content

send mouse click in an inactive windows


Recommended Posts

hi. so im new to autoit and i know this was discussed 1000 times but i cant find a working script as an exaple to start from. so basicly i have an inactive window where i need to click on checkbox. by pressing specific button (cud be any numpad1 numpad2 doesnt matter) it shud check and uncheck checkbox

AYRMdxZ.png

can anyone share a working script so i can learn how to do it? thanks and sorry for bad english its not my native tongue

Link to comment
Share on other sites

  • Moderators

@denissko Welcome to the forum. What have you tried? Your title mentions mouseclick; but if you want to send to an inactive window you need to use the Control* commands. Also, it is a little difficult to offer suggestions when all you're giving us is a 1/2" screenshot and a request for someone to write the script for you. How about a detailed description of the App you're working with, and what the AutoIt Window Info Tool returns about that window?

Edited by JLogan3o13

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

1 hour ago, JLogan3o13 said:

@denissko Welcome to the forum. What have you tried? Your title mentions mouseclick; but if you want to send to an inactive window you need to use the Control* commands. Also, it is a little difficult to offer suggestions when all you're giving us is a 1/2" screenshot and a request for someone to write the script for you. How about a detailed description of the App you're working with, and what the AutoIt Window Info Tool returns about that window?

i have inactive window called "Edit rules" and the checkbox i posted above

by pressing f1 it shud check that checkbox and by pressing f2 in shud uncheck it

heres my script

HotKeySet("F1", "Start")
HotKeySet("F2", "Pause")

While 1
Sleep(500)
WEnd

Func Start()
controlClick("Edit rules","left",196,94,1)
pause()
EndFunc

Func Pause()
    While 1
    Sleep(500)
    WEnd
EndFunc

why it does not work?

Link to comment
Share on other sites

and heres what window info tool returns about that window

>>>> Window <<<<
Title:  Edit Rules
Class:  WindowsForms10.Window.8.app.0.282af8c_r12_ad1
Position:   -8, -8
Size:   1936, 1056
Style:  0x17CD0000
ExStyle:    0x00010100
Handle: 0x00000000001D044C

>>>> Control <<<<
Class:  WindowsForms10.SysListView32.app.0.282af8c_r12_ad1
Instance:   1
ClassnameNN:    WindowsForms10.SysListView32.app.0.282af8c_r12_ad11
Name:   list
Advanced (Class):   [NAME:list]
ID: 7602818
Text:   
Position:   1, 32
Size:   1918, 900
ControlClick Coords:    188, 33
Style:  0x560180C9
ExStyle:    0x00000200
Handle: 0x0000000000740282

>>>> Mouse <<<<
Position:   189, 87
Cursor ID:  0
Color:  0x6778A7

>>>> StatusBar <<<<

>>>> ToolsBar <<<<

>>>> Visible Text <<<<
Search
v
Save
Load
statusStrip1
Close
Process rules first, then custom processes priorities second
Delete
Edit
Add
Down
Up


>>>> Hidden Text <<<<

 

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...