Microsoft Surface Hub 2 SmCamera User Manual

Page 527

Advertising
background image

}
}
}

else

{
$status[

"Device Password Policy"

] =

"Failed to apply the EAS policy to

the account."

PrintError

"Failed to obtain policy"

}
PrintSuccess

"Account creation completed."

PrintAction

"Setting calendar processing rules..."

$Error.Clear();

## Prepare the calendar for automatic meeting responses ##

try

{

Set-CalendarProcessing

-Identity

$credNewAccount.UserName

-

AutomateProcessing

AutoAccept

} catch { }

if

($Error)

{
$status[

"Calendar Acceptance"

] =

"Failed to configure the account to

automatically accept/decline meeting requests"

}

else

{
$status[

"Calendar Acceptance"

] =

"Successfully configured the account to

automatically accept/decline meeting requests"

}

$Error.Clear()

try

{

Set-CalendarProcessing

-Identity

$credNewAccount.UserName

-

RemovePrivateProperty

$false

-AddOrganizerToSubject

$false

-

AddAdditionalResponse

$true

-DeleteSubject

$false

-DeleteComments

$false

-

AdditionalResponse

"This is a Surface Hub room!"

} catch { }

if

($Error)

{
$status[

"Calendar Response Configuration"

] =

"Failed to configure the

account's response properties"

}

else

{
$status[

"Calendar Response Configuration"

] =

"Successfully configured

the account's response properties"

}

$Error.Clear()

## Configure the Account to not expire ##

PrintAction

"Configuring password not to expire..."

try

{

Set-MsolUser

-UserPrincipalName

$credNewAccount.UserName

-

Advertising