Project by FirePanther
1c6bdde2e1dc69a5ffb9533dea92be7f

Nicht angemeldet.

AutoIt-Pastebin

Auf AutoIt-Pastebin können Sie Ihre Skripte und Codeschnipsel einfügen und anderen eine farblich hervorgehobene Seite zeigen

Userinformation - Eintrag von Mahagon

Details:
Das Skript wird niemals automatisch gelöscht.
Es wurde am 26.07.10 um 20:52 Uhr veröffentlicht und hatte bisher 309 Besucher.
#Region ;**** Directives created by AutoIt3Wrapper_GUI ****
#AutoIt3Wrapper_Icon=Userinformation.ico
#AutoIt3Wrapper_UseX64=n
#AutoIt3Wrapper_Change2CUI=y
#EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****
#cs ----------------------------------------------------------------------------
 
AutoIt Version: 3.3.6.1
Author: Daniel Jacobs (Mahagon)
 
Script Function:
Gibt Informationen eines Benutzers auf der Kommandozeile zurück
 
License:
 
The content of this work is licensed under Creative Commons license.
You are allowed to use and change it as u wish as long as you mention me as the Author.
 
Der Inhalt dieses Werkes ist lizensiert unter der Creative Commons Lizenz.
Sie dürfen es nutzen und verändert solange ich als Autor genannt werde.
 
#ce ----------------------------------------------------------------------------
 
#include "WinWMI_UserAccount.au3"
 
Const $ae = Chr(132)
Const $_AE = Chr(142)
Const $oe = Chr(148)
Const $_OE = Chr(153)
Const $ue = Chr(129)
Const $_UE = Chr(154)
 
 
 
$aReturn = _WinWMI_UserAccount_GetInformation("Name,FullName,Caption,Description" & _
",Disabled,Domain,LocalAccount,Lockout,PasswordChangeable,PasswordExpires,Password" & _
"Required,SID,Status") ;Felder, welche Abgefragt werden sollen
If @error Then
ConsoleWrite("Fehler: Programm konnte nicht ausgeführt werden." & @CRLF & _
"Errorcode: " & @error & @CRLF) ;Gibt einen Fehler aus, falls der Benutzer
;nicht gefunden wurde oder der Zugriff auf die WMI fehlgeschlagen ist
 
Exit
EndIf
 
For $iCountLines = 0 To UBound($aReturn) - 1 ;Passt die Rückgabewerte True, False und "" an
$sCw = ""
For $iCountFields = 0 To UBound($aReturn, 2) - 1
If $aReturn[$iCountLines][$iCountFields] == False Then
$aReturn[$iCountLines][$iCountFields] = "Nein"
ElseIf $aReturn[$iCountLines][$iCountFields] == True Then
$aReturn[$iCountLines][$iCountFields] = "Ja"
ElseIf $aReturn[$iCountLines][$iCountFields] == "" Then
$aReturn[$iCountLines][$iCountFields] = "Keine Angaben"
EndIf
$aReturn[$iCountLines][$iCountFields] = StringReplace($aReturn[$iCountLines][$iCountFields], "ä", $ae, 0, 1)
$aReturn[$iCountLines][$iCountFields] = StringReplace($aReturn[$iCountLines][$iCountFields], "Ä", $_AE, 0, 1)
$aReturn[$iCountLines][$iCountFields] = StringReplace($aReturn[$iCountLines][$iCountFields], "ö", $oe, 0, 1)
$aReturn[$iCountLines][$iCountFields] = StringReplace($aReturn[$iCountLines][$iCountFields], "Ö", $_OE, 0, 1)
$aReturn[$iCountLines][$iCountFields] = StringReplace($aReturn[$iCountLines][$iCountFields], "ü", $ue, 0, 1)
$aReturn[$iCountLines][$iCountFields] = StringReplace($aReturn[$iCountLines][$iCountFields], "Ü", $_UE, 0, 1)
$sCw &= $aReturn[$iCountLines][$iCountFields] & ":"
Next
ConsoleWrite(StringTrimRight($sCw,1) & @CRLF)
Next