Suche ein best. Macro

  • Hi,
    gibt es für:

    [autoit]


    @UserProfileDir & '\Lokale Einstellungen\Anwendungsdaten\Identities\'

    [/autoit]


    noch ein anderes Macro (es ist NICHT "@AppDataDir" oder "@AppDataCommonDir") ?

    Frage ich, dass jetzt so ab ?

    [autoit]


    Dim $test, $ident = RegRead("HKEY_CURRENT_USER\Identities", "Default User ID") ;i Identities read

    [/autoit][autoit][/autoit][autoit]

    If FileExists(@UserProfileDir & '\Lokale Einstellungen\Anwendungsdaten\Identities\' & $ident & '\Microsoft\Outlook Express\') Then
    $test = @UserProfileDir & '\Lokale Einstellungen\Anwendungsdaten\Identities\' & $ident & '\Microsoft\Outlook Express\'
    MsgBox(0, "\Lokale Einstellungen\Anwendungsdaten\Identities\", $test & @TAB)
    ElseIf FileExists(@UserProfileDir & "\Local Settings\Application Data\Identities\" & $ident & '\Microsoft\Outlook Express\') Then
    $test = @UserProfileDir & "\Local Settings\Application Data\Identities\" & $ident & '\Microsoft\Outlook Express\'
    MsgBox(0, "\Local Settings\Application Data\Identities\", $test & @TAB)
    EndIf

    [/autoit]

    Danke :thumbup:

  • Du kannst es aus der Registry auslesen:

    Spoiler anzeigen
    [autoit]

    MsgBox(0, '', @AppDataDir)
    MsgBox(0, '', _Local_AppData())

    [/autoit] [autoit][/autoit] [autoit]

    ; Prog@ndy
    Func _Local_AppData()
    Return _ShellFolders_Read("Local AppData")
    EndFunc

    [/autoit] [autoit][/autoit] [autoit]

    ; Prog@ndy
    Func _Local_Settings()
    Return _ShellFolders_Read("Local Settings")
    EndFunc

    [/autoit] [autoit][/autoit] [autoit]

    ;===============================================================================
    ;
    ; Function Name: _ShellFolders_Read
    ; Description:: Reads the path of shellfolders from registry
    ; Parameter(s): $FolderName - name of folder, see below
    ; Requirement(s): RegRead
    ; Return Value(s): value, @error and @extended like RegRead
    ; Author(s): Prog@ndy
    ; Possible FolderNames:
    #cs ---------------------------------------
    ; * AppData
    ; * Cookies
    ; * Desktop
    ; * Favorites
    ; * NetHood
    ; * Personal
    ; * PrintHood
    ; * Recent
    ; * SendTo
    ; * Start Menu
    ; * Templates
    ; * Programs
    ; * Startup
    ; * Local Settings
    ; * Local AppData
    ; * Cache
    ; * History
    ; * My Pictures
    ; * Fonts
    ; * My Music
    ; * CD Burning
    ; * My Video
    ; * Administrative Tools
    #ce ---------------------------------------
    ;===============================================================================
    ;

    [/autoit] [autoit][/autoit] [autoit]

    Func _ShellFolders_Read($FolderName)
    Local Const $__SpecialFolders_ShellFolders_Reg = "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders"
    Local $Path = RegRead($__SpecialFolders_ShellFolders_Reg,$FolderName)
    Return SetError(@error,@extended,$Path)
    EndFunc

    [/autoit]