0 votes

According to this article when we disable a user we should "Disable Exchange ActiveSync and Disable OWA for Devices, and Disable email connectivity." However I can only figure out how to disable ActiveSync with adaxes. Is there a way to Disable "OWA for Devices" and "Email connectivity" as well?

https://support.office.com/en-us/articl ... 5eddb367d1

by (1.8k points)

1 Answer

0 votes
by (217k points)
selected by
Best answer

Hello,

To disable Exchange ActiveSync and email connectivity, you need to disable the following Exchange Features: Exchange ActiveSync and Outlook Web App.


As for OWA for Devices, currently the feature is not supported by Adaxes natively. By the time when we were developing our Exchange ADSI API that is used by Adaxes to interact with Exchange, the feature was still in development by Microsoft. Depending on various preview builds of Exchange 2013, it appeared, and then disappeared, and then appeared again, so we decided not to implement it until a final decision is made by Microsoft. Now, that things seem to have settled down, we'll add the support for it in one of the future releases.

For now, you can disable the feature with the help of a PowerShell script. You can create a Custom Command that will disable the feature by running a script or add a script to an existing Custom Command, Scheduled Task or Business Rule. To add such a script:

  1. Add the Run a program or PowerShell script action to your Business Rule, Custom Command or Scheduled Task.

  2. In the Script field, paste the following script:

     try
     {
         $objectId = [Guid]$Context.TargetObject.Get("adm-O365ObjectId")
     }
     catch
     {
         return # No office 365 account
     }
    
     $session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri "https://ps.outlook.com/powershell/" `
         -Credential $Context.GetOffice365Credential() -Authentication Basic -AllowRedirection
     Import-PSSession $Session -AllowClobber -DisableNameChecking
    
     Set-CASMailbox $objectId.ToString() -OWAforDevicesEnabled $false
    
     Remove-PSSession $session
    
  3. Add a short description for the script and click OK.

0

Works great! Thank you!

Related questions

0 votes
1 answer

My scheduled task currently: Checks for staff in a particular OU that do not have an O365 license Adds a license Resets their AD Password Moves them to an OU based off ... scheduled task moves them out of the OU that the business rule is looking at. Thanks

asked Apr 15 by russmerriman (450 points)
0 votes
1 answer

Is it possible to disable then re-enable a Business Rule from a Scheduled Task? For example, when the Scheduled tasks starts, it disables a Business Rule, runs the Task(s), then re-enables the Business Rule when done.

asked May 11, 2016 by Kikaida (4.8k points)
0 votes
1 answer

I would like to add the following logic into a Powershell script that will be triggered on 'After Create User'. Read the value of the 'title' property of the user just created ... 'True' or 'False'. Could you assist with how to script this please? Many thanks.

asked May 1 by Bernie (1.8k points)
0 votes
1 answer

When creating business rules I quite often find myself having to create overly complex workflows because we can't use ELSE or BREAK statements. An example would be:- ... am I missing something in how to construct business rules that mimics their use? Thanks

asked Sep 23, 2014 by firegoblin (11k points)
0 votes
1 answer

Hi again ! Is there a way in a BR Powershell script to get the Domain Controller Adaxes service is using for an operation. To be clearer, i use a powershell script in a ... can get the DC in the context, i could pass it to the powershell cmdlet. Thanks Stephen

asked Jun 22, 2012 by sroux (7k points)
2,352 questions
2,107 answers
5,746 comments
131,525 users