Update UnlockScript.ps1

This commit is contained in:
jnisbet 2024-03-06 16:36:09 +00:00
parent 2b9f64d4fd
commit 4e02ef5711
1 changed files with 2 additions and 2 deletions

View File

@ -11,7 +11,7 @@ $group_linked_ou = [PSCustomObject]@{
#List of security groups taken from the object above #List of security groups taken from the object above
$group_keys = $group_linked_ou | ForEach-Object {$_.psobject.properties.name} $group_keys = $group_linked_ou | ForEach-Object {$_.psobject.properties.name}
#$env:username
#Get current logged in user #Get current logged in user
$logged_in_user = Get-ADUser -Identity $env:username -Properties MemberOf $logged_in_user = Get-ADUser -Identity $env:username -Properties MemberOf
@ -58,7 +58,7 @@ $users_to_unlock = list_ou_members -ou_dns $ou_dn_list
#GUI creation #GUI creation
$form = New-Object System.Windows.Forms.Form $form = New-Object System.Windows.Forms.Form
$form.Text = 'Select a Computer' $form.Text = 'Unlock Account'
$form.Size = New-Object System.Drawing.Size(400,200) $form.Size = New-Object System.Drawing.Size(400,200)
$form.StartPosition = 'CenterScreen' $form.StartPosition = 'CenterScreen'