Public/Enable-Account.ps1

function Enable-Account {

    <#
    .SYNOPSIS
    -Taylor Lee
    Modified 05172019
 
    .DESCRIPTION
    Enables a specified Active Directory Account
 
    .NOTES
    Requires the Active Directory Module
 
    .Parameter Account
    Account that is being enabled
 
    .EXAMPLE
    Use the Samaccountname of the account being disabled
 
     Enable-ADAccount -Account JohnD
 
    .EXAMPLE
    Use the DistinguishedName of the account being disabled
 
    Enable-ADAccount -Account "CN=John Doe,OU=Finance,OU=UserAccounts,DC=FABRIKAM,DC=COM"
 
    .EXAMPLE
    Use the UserPrincipalName of the account being disabled
 
    Enable-ADAccount -Account PJohnD@Company.com
 
    .Link
    Connect-SSH
    Enable-PSRemoting
    Install-SSH
    #>


    [CmdletBinding()]

    Param (
        [Parameter(Mandatory = $true)]$Account
    )

    Import-Module ActiveDirectory

    Enable-ADAccount -Identity $Account -Confirm
}