Jump to content
c7aesa7r

Help with window info

Recommended Posts

c7aesa7r

I have a program named NetLimiter, that can block or limit the internet traffic of others programs.

Trying do a autoitscript to when runned, tick that red circle box in image, but when i run autoit winndow spy and drag the finder tool to that checkbox it dont detect it, how i can do this script then?

 

Screenshot_1.png

Edited by c7aesa7r

Share this post


Link to post
Share on other sites
c7aesa7r

Anyone to help please?

Share this post


Link to post
Share on other sites
Danyfirex

Share this post


Link to post
Share on other sites
c7aesa7r

-Double Post, accidentally

Edited by c7aesa7r

Share this post


Link to post
Share on other sites
c7aesa7r
9 hours ago, Danyfirex said:

check here.

 

Saludos

 

Your link send me to my post page, it was a joke?

 

8 hours ago, junkew said:

I'll try it, thank you.

Share this post


Link to post
Share on other sites
Danyfirex

Hello. Sorry c7aesa7r I meant same link as junkew.

 

Saludos

Share this post


Link to post
Share on other sites
c7aesa7r

Any guidance now? trying a script to tick that checkbox, when i press a hotkey, with that i can pause, reduce, limit etc the upload/download of any program running from background.

asaaaa.png

Mouse position is retrieved 490-330
At least we have an element title: [] class: [CheckBox]

Having the following values for all properties: 
Title is: <>    Class   := <CheckBox>   controltype:= <UIA_CheckBoxControlTypeId>   ,<50002>    , (0000C352)    479;321;20;20
*** Parent Information top down ***
5: Title is: <NetLimiter 4> Class   := <Window> controltype:= <UIA_WindowControlTypeId> ,<50032>    , (0000C370)    -6;0;1152;974
"Title:=NetLimiter 4;controltype:=UIA_WindowControlTypeId;class:=Window""   
4: Title is: <> Class   := <TabsCtrl>   controltype:= <UIA_CustomControlTypeId> ,<50025>    , (0000C369)    7;107;672;854
"Title:=;controltype:=UIA_CustomControlTypeId;class:=TabsCtrl"" 
3: Title is: <> Class   := <ActivityCtrl>   controltype:= <UIA_CustomControlTypeId> ,<50025>    , (0000C369)    7;142;672;819
"Title:=;controltype:=UIA_CustomControlTypeId;class:=ActivityCtrl"" 
2: Title is: <> Class   := <ListView>   controltype:= <UIA_DataGridControlTypeId>   ,<50028>    , (0000C36C)    7;179;672;782
"Title:=;controltype:=UIA_DataGridControlTypeId;class:=ListView""   
1: Title is: <NLClientApp.Core.ViewModels.AppActivityNode>  Class   := <ListViewItem>   controltype:= <UIA_DataItemControlTypeId>   ,<50029>    , (0000C36D)    7;316;789;30
"Title:=NLClientApp.Core.ViewModels.AppActivityNode;controltype:=UIA_DataItemControlTypeId;class:=ListViewItem""    
0: Title is: <> Class   := <ContentPresenter>   controltype:= <UIA_CustomControlTypeId> ,<50025>    , (0000C369)    479;321;98;20
"Title:=;controltype:=UIA_CustomControlTypeId;class:=ContentPresenter"" 


;~ *** Standard code maintainable ***
#include "UIAWrappers.au3"
AutoItSetOption("MustDeclareVars", 1)

_UIA_setVar("oP1","Title:=NetLimiter 4;controltype:=UIA_WindowControlTypeId;class:=Window") ;NetLimiter 4
_UIA_setVar("oP2","Title:=;controltype:=UIA_CustomControlTypeId;class:=TabsCtrl")   ;
_UIA_setVar("oP3","Title:=;controltype:=UIA_CustomControlTypeId;class:=ActivityCtrl")   ;
_UIA_setVar("oP4","Title:=;controltype:=UIA_DataGridControlTypeId;class:=ListView") ;
_UIA_setVar("oP5","Title:=NLClientApp.Core.ViewModels.AppActivityNode;controltype:=UIA_DataItemControlTypeId;class:=ListViewItem")  ;NLClientApp.Core.ViewModels.AppActivityNode
_UIA_setVar("oP6","Title:=;controltype:=UIA_CustomControlTypeId;class:=ContentPresenter")   ;

;~ $oUIElement=_UIA_getObjectByFindAll(".mainwindow", "title:=;ControlType:=UIA_CheckBoxControlTypeId", $treescope_subtree)
_UIA_setVar("oUIElement","Title:=;controltype:=UIA_CheckBoxControlTypeId;class:=CheckBox") ;ControlType:=UIA_CheckBoxControlTypeId;classname:=CheckBox")

;~ Actions split away from logical/technical definition above can come from configfiles 

;~_UIA_Action("oP1","highlight")
_UIA_Action("oP1","setfocus")
;~_UIA_Action("oP2","highlight")
_UIA_Action("oP2","setfocus")
;~_UIA_Action("oP3","highlight")
_UIA_Action("oP3","setfocus")
;~_UIA_Action("oP4","highlight")
_UIA_Action("oP4","setfocus")
;~_UIA_Action("oP5","highlight")
_UIA_Action("oP5","setfocus")
;~_UIA_Action("oP6","highlight")
_UIA_Action("oP6","setfocus")

;~_UIA_action($oUIElement","highlight")
;~_UIA_action($oUIElement,"click")
;~_UIA_action("oUIElement","highlight")
;~_UIA_action("oUIElement","click")


;~ *** Standard code Flexible***
#include "UIAWrappers.au3"
AutoItSetOption("MustDeclareVars", 1)

Local $oP5=_UIA_getObjectByFindAll($UIA_oDesktop, "Title:=NetLimiter 4;controltype:=UIA_WindowControlTypeId;class:=Window", $treescope_children)    
_UIA_Action($oP5,"setfocus")
Local $oP4=_UIA_getObjectByFindAll($oP5, "Title:=;controltype:=UIA_CustomControlTypeId;class:=TabsCtrl", $treescope_children)   
Local $oP3=_UIA_getObjectByFindAll($oP4, "Title:=;controltype:=UIA_CustomControlTypeId;class:=ActivityCtrl", $treescope_children)   
Local $oP2=_UIA_getObjectByFindAll($oP3, "Title:=;controltype:=UIA_DataGridControlTypeId;class:=ListView", $treescope_children) 
Local $oP1=_UIA_getObjectByFindAll($oP2, "Title:=NLClientApp.Core.ViewModels.AppActivityNode;controltype:=UIA_DataItemControlTypeId;class:=ListViewItem", $treescope_children)  
Local $oP0=_UIA_getObjectByFindAll($oP1, "Title:=;controltype:=UIA_CustomControlTypeId;class:=ContentPresenter", $treescope_children)   
;~ First find the object in the parent before you can do something
;~$oUIElement=_UIA_getObjectByFindAll(".mainwindow", "title:=;ControlType:=UIA_CheckBoxControlTypeId", $treescope_subtree)
Local $oUIElement=_UIA_getObjectByFindAll($oP0, "title:=;ControlType:=UIA_CheckBoxControlTypeId", $treescope_subtree)
;~_UIA_action($oUIElement,"highlight")
_UIA_action($oUIElement,"click")


*** Detailed properties of the highlighted element ***
UIA_class:= <CheckBox>
UIA_regexpclass:= <CheckBox>
UIA_iaccessiblechildId:= <0>
UIA_handle:= <0>
UIA_RuntimeId:= <7;8244;19325759>
UIA_BoundingRectangle:= <479;321;20;20>
UIA_ProcessId:= <8244>
UIA_ControlType:= <50002>
UIA_LocalizedControlType:= <caixa de seleção>
UIA_HasKeyboardFocus:= <False>
UIA_IsKeyboardFocusable:= <True>
UIA_IsEnabled:= <True>
UIA_ClassName:= <CheckBox>
UIA_ClickablePoint:= <489;331>
 

 

 

 

Edited by c7aesa7r

Share this post


Link to post
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

×