Re: Combining Powershell object properties

Tech-Archive recommends: Fix windows errors by optimizing your registry



Hello Nick,

Are you trying to populate an Exchange field with this information, or just use it in your sript?

You could do

$user = get-user <alias>
$fullname = $user.FirstName + $user.lastname

now, $fullnae eill be 'firstnamelastname' with no spaces.

Karl


Hi,

I was wondering how you would combine two existing object properties
into one (in Powershell)? I.E. $_.firstname + $_.lastname =
$_.fullname

Do you need to you the add-member cmdlet?

Thanks,
-Nick


.