Solved

Exchange 2010 powershell script not working

Posted on 2014-09-30
1
102 Views
Last Modified: 2014-09-30
Afternoon,

I have the following script which is asking to confirm each and every time it removes the permissions

Import-csv C:\Temp\aliaslist.csv | Foreach {Get-Mailbox -identity $_.Alias | Remove-MailboxPermission -User wsht.local\svc.qmm -AccessRights FullAccess -InheritanceType All}

Open in new window


I've added a -confirm: $false after inheritancetype all and that still doesn't work. How do I stop prompting and automatically accept?

Thanks

Alex
0
Comment
Question by:Alex Green
1 Comment
 
LVL 8

Accepted Solution

by:
Acosta Technology Services earned 500 total points
ID: 40352007
You can set confirm preference to"none".

$ConfirmPreference = 'None'
0

Featured Post

Optimizing Cloud Backup for Low Bandwidth

With cloud storage prices going down a growing number of SMBs start to use it for backup storage. Unfortunately, business data volume rarely fits the average Internet speed. This article provides an overview of main Internet speed challenges and reveals backup best practices.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Public Folder Migration from Exchange 2010 to Office 365 19 54
Exchange 2016 Cloud Witness 1 39
exchange 2013 search-mailbox question 7 42
ACTIVE DIRECTORY 18 49
Utilizing an array to gracefully append to a list of EmailAddresses
Disabling the Directory Sync Service Account in Office 365 will stop directory synchronization from working.
The video tutorial explains the basics of the Exchange server Database Availability groups. The components of this video include: 1. Automatic Failover 2. Failover Clustering 3. Active Manager
To add imagery to an HTML email signature, you have two options available to you. You can either add a logo/image by embedding it directly into the signature or hosting it externally and linking to it. The vast majority of email clients display l…

773 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question