$fullnamexp = ((net user $winxp /domain | Select-String \"Full Name\") -replace \"Full Name\",\"\").Trim();
If $winxp cannot be found,
$winxp
Does this help?
$query = (dsquery user -samid $winxp) if ($query) {$fullnamexp = ($query | dsget user -display)[1].trim()} $fullnamexp