Conocer el nombre del usuario activo.

(Borland)

function CurrentUserName:String;  
var  
  u: array[0..127] of Char;  
  sz:DWord;  
begin  
  sz:=SizeOf(u);  
  GetUserName(u,sz);  
  Result:=u;  
end;  

procedure TForm1.Button1Click(Sender: TObject);  
begin  
  ShowMessage(CurrentUsername);  
end;