Jump to content

How to get Control Id of file for which WindowInfo Tool does not focus - (Moved)


Recommended Posts

I am trying to open my downloads folder and select .exe file (This file name changes on multiple downloads therefore cannot give path). The issue is that the window info tool focus on entire download list as a whole and doe snot provide me control id for each item in the list.

Link to comment
Share on other sites

  • Moderators

Moved to the appropriate forum.

Moderation Team

Public_Domain.png.2d871819fcb9957cf44f4514551a2935.png Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind

Open spoiler to see my UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Link to comment
Share on other sites

the window info tool give just info for

  • Window titles
  • Text on the window (visible and hidden)
  • Window size and position
  • Contents of the status bar
  • Position of the mouse pointer
  • Color of the pixels underneath the mouse pointer
  • Details of the Control underneath the mouse pointer

 

try this if it help you :)

#AutoIt3Wrapper_AU3Check_Parameters=-d -w 1 -w 2 -w 3 -w 4 -w 5 -w 6 -w 7
#include <File.au3>

_FindAllFile()

;----------------------------------------------------------------------------------------
Func _FindAllFile()
    Local $dir = @HomeDrive & @HomePath & "\Downloads\"
    Local $ArraySrtfiles = _FileListToArrayRec($dir, "*.exe", $FLTAR_FILES, $FLTAR_NORECUR)
    If Not IsArray($ArraySrtfiles) Then
        ConsoleWrite($dir & " = Invalid input path" & @CRLF)
        Return
    Else
        Local $sFilePath
        For $x = 1 To $ArraySrtfiles[0]
            $sFilePath = $dir & $ArraySrtfiles[$x]
            ConsoleWrite($sFilePath & " -> Timestamp:" & FileGetTime($sFilePath, $FT_MODIFIED, 1) & @CRLF)
        Next
    EndIf
EndFunc   ;==>_FindAllFile
;----------------------------------------------------------------------------------------

 

I know that I know nothing

Link to comment
Share on other sites

  • 3 weeks later...

What browser do you use?

For Chrome e.g. the default download location can be found this way:

 

$Str = "\\\\fdjakl\\fldias\\fdasköl"
$Str = StringReplace($Str, "\\", "\")
ConsoleWrite('@@ Debug(' & @ScriptLineNumber & ') : $Str = ' & $Str & @CRLF & '>Error code: ' & @error & @CRLF) ;### Debug Console
Exit


$RegExDL_Dir = '(?i)^(?:.*?"download":{"default_directory":")([^"]+)(?:".*$)'
$StrPreferences = FileRead(@LocalAppDataDir & "\Google\Chrome\User Data\Default\Preferences")
If StringRegExp($StrPreferences, $RegExDL_Dir) Then
    $DLDir = StringRegExpReplace($StrPreferences, $RegExDL_Dir, "$1")
    $DLDir = StringReplace($DLDir, "\\", "\")
    #cs <edit> - not required, as "\\\\" will be reduced to "\\" and not "\"
    if StringLeft($DLDir,1)="\" then $DLDir = "\" & $DLDir
    #ce <edit> - not required, as "\\\\" will be reduced to "\\" and not "\"
Else
    $DLDir = @UserProfileDir & "\Downloads"
EndIf

ConsoleWrite('@@ Debug(' & @ScriptLineNumber & ') : $DLDir = ' & $DLDir & @CRLF & '>Error code: ' & @error & @CRLF) ;### Debug Console

once that is known monitor the folder for new EXE files to show up

 

Edited by rudi

Earth is flat, pigs can fly, and Nuclear Power is SAFE!

Link to comment
Share on other sites

I mainly use firefox, I use chrome for translations, both use the default windows Downloads folder 

in the location C:\Users\<UserName>\Downloads\    which, however, changes if you want, to both

in chrome in   chrome://settings/downloads     in Firefox in  about:preferences   in the section Files and Applications

 

 

Edited by ioa747

I know that I know nothing

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...