< Back

Get-UserBaseName

Sun Jan 12, 2020 6:01 pm

NAME Get-UserBaseName



SYNOPSIS

Returns the base part of the username given a full username





SYNTAX

Get-UserBaseName [-UserName] <String> [<CommonParameters>]





DESCRIPTION

Returns the base part of the username given a full username. If its a distringuished name the first part of the

user object is used





PARAMETERS

-UserName <String>

The full username that will be parsed



Required? true

Position? 1

Default value

Accept pipeline input? false

Accept wildcard characters? false



<CommonParameters>

This cmdlet supports the common parameters: Verbose, Debug,

ErrorAction, ErrorVariable, WarningAction, WarningVariable,

OutBuffer, PipelineVariable, and OutVariable. For more information, see

about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).



INPUTS



OUTPUTS



-------------------------- EXAMPLE 1 --------------------------



PS C:\\># Returns myuserid from the fullusername provided



Get-UserBaseName "LOCALDOMAIN\\myuserid"











RELATED LINKS