c7aesa7r

Help with window info

10 posts in this topic

#1 ·  Posted (edited)

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



#2 ·  Posted

Anyone to help please?

Share this post


Link to post
Share on other sites

#3 ·  Posted

Share this post


Link to post
Share on other sites

#5 ·  Posted (edited)

-Double Post, accidentally

Edited by c7aesa7r

Share this post


Link to post
Share on other sites

#6 ·  Posted

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

#7 ·  Posted

Hello. Sorry c7aesa7r I meant same link as junkew.

 

Saludos

Share this post


Link to post
Share on other sites

#8 ·  Posted (edited)

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>
UIA_Culture:= <0>
UIA_IsControlElement:= <True>
UIA_IsContentElement:= <True>
UIA_IsPassword:= <False>
UIA_NativeWindowHandle:= <0>
UIA_IsOffscreen:= <False>
UIA_Orientation:= <0>
UIA_FrameworkId:= <WPF>
UIA_IsRequiredForForm:= <False>
UIA_IsDockPatternAvailable:= <False>
UIA_IsExpandCollapsePatternAvailable:= <False>
UIA_IsGridItemPatternAvailable:= <False>
UIA_IsGridPatternAvailable:= <False>
UIA_IsInvokePatternAvailable:= <False>
UIA_IsMultipleViewPatternAvailable:= <False>
UIA_IsRangeValuePatternAvailable:= <False>
UIA_IsScrollPatternAvailable:= <False>
UIA_IsScrollItemPatternAvailable:= <False>
UIA_IsSelectionItemPatternAvailable:= <False>
UIA_IsSelectionPatternAvailable:= <False>
UIA_IsTablePatternAvailable:= <False>
UIA_IsTableItemPatternAvailable:= <False>
UIA_IsTextPatternAvailable:= <False>
UIA_IsTogglePatternAvailable:= <True>
UIA_IsTransformPatternAvailable:= <False>
UIA_IsValuePatternAvailable:= <False>
UIA_IsWindowPatternAvailable:= <False>
UIA_ValueIsReadOnly:= <True>
UIA_RangeValueValue:= <0>
UIA_RangeValueIsReadOnly:= <True>
UIA_RangeValueMinimum:= <0>
UIA_RangeValueMaximum:= <0>
UIA_RangeValueLargeChange:= <0>
UIA_RangeValueSmallChange:= <0>
UIA_ScrollHorizontalScrollPercent:= <0>
UIA_ScrollHorizontalViewSize:= <100>
UIA_ScrollVerticalScrollPercent:= <0>
UIA_ScrollVerticalViewSize:= <100>
UIA_ScrollHorizontallyScrollable:= <False>
UIA_ScrollVerticallyScrollable:= <False>
UIA_SelectionCanSelectMultiple:= <False>
UIA_SelectionIsSelectionRequired:= <False>
UIA_GridRowCount:= <0>
UIA_GridColumnCount:= <0>
UIA_GridItemRow:= <0>
UIA_GridItemColumn:= <0>
UIA_GridItemRowSpan:= <1>
UIA_GridItemColumnSpan:= <1>
UIA_DockDockPosition:= <5>
UIA_ExpandCollapseExpandCollapseState:= <3>
UIA_MultipleViewCurrentView:= <0>
UIA_WindowCanMaximize:= <False>
UIA_WindowCanMinimize:= <False>
UIA_WindowWindowVisualState:= <0>
UIA_WindowWindowInteractionState:= <0>
UIA_WindowIsModal:= <False>
UIA_WindowIsTopmost:= <False>
UIA_SelectionItemIsSelected:= <False>
UIA_TableRowOrColumnMajor:= <2>
UIA_ToggleToggleState:= <0>
UIA_TransformCanMove:= <False>
UIA_TransformCanResize:= <False>
UIA_TransformCanRotate:= <False>
UIA_IsLegacyIAccessiblePatternAvailable:= <True>
UIA_LegacyIAccessibleChildId:= <0>
UIA_LegacyIAccessibleRole:= <44>
UIA_LegacyIAccessibleState:= <1048576>
UIA_LegacyIAccessibleDefaultAction:= <Verificar>
UIA_IsDataValidForForm:= <False>
UIA_ProviderDescription:= <[pid:8244,hwnd:0x0 Main(parent link):Unidentified Provider (managed:MS.Internal.Automation.ElementProxy, PresentationCore, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35)]>
UIA_IsItemContainerPatternAvailable:= <False>
UIA_IsVirtualizedItemPatternAvailable:= <False>
UIA_IsSynchronizedInputPatternAvailable:= <True>

 

 

 

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