< Back

Test-CUser

Sun Jan 12, 2020 11:35 pm

NAME Test-CUser



SYNOPSIS

Checks if a *local* user account exists.





SYNTAX

Test-CUser [-Username] <String> [<CommonParameters>]





DESCRIPTION

Uses .NET's AccountManagement API to check if a *local* user account exists. Returns `True` if the *local*

account exists, or `False` if it doesn't.





PARAMETERS

-Username <String>

The username of the *local* account to check



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

System.Boolean





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



PS C:\\>Test-CUser -Username HSolo



Checks if the HSolo *local* account exists. Returns `True` if it does, `False` if it doesn't or its encased in

carbonite.











RELATED LINKS

Get-CUser

Install-CUser

Uninstall-CUser