| |
|
|
|
Description:
GetUserName determined whom Usernamen the eingeloggten Users for actually Thread.
Deklaration:
Def @GetUserName(2) !ADVAPI32,GetUserNameA
Parameter:
1.Parameter: Memory-Variable, The whom Usernamen aufnimmt. 2.Parameter: 4 byte large Memory-Variable, in the The Size the Bereichs of Parameter 1 in Bytes standing. Kehrt The function back, standing here The length the Usenamens plus the abschließende Nullbyte.
Return Value:
1 with success, 0 with failure.
Examples:
CompileMarkSeparationDef @GetUserName(2) !"ADVAPI32","GetUserNameA"
Declare USize#,UName#,Fehler&
Windowstyle 31
Windowtitle "Usernamen ermitteln"
Window 0,0-640,440
Dim Usize#,4
Dim UName#,256
LONG Usize#,0=256
LET FEHLER&=@GetUserName(UName#,Usize#)
PRINT "API Fehlercode="+@STR$(Fehler&)
Print "Username="+@String$(UName#,0)
Print "Länge mit abschließendem Nullbyte="+@STR$(@Long(USize#,0))
Dispose UName#
Dispose Usize#
While 0=0
Waitinput
wend
[keywords:71b84696e8] user User actually announced detect [/keywords:71b84696e8] |
|
|
| |
|
|