AD to Office 365 Powershell Commands

%3CLINGO-SUB%20id%3D%22lingo-sub-1335758%22%20slang%3D%22en-US%22%3EAD%20to%20Office%20365%20Powershell%20Commands%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1335758%22%20slang%3D%22en-US%22%3E%3CP%3EHi%2C%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI'm%20fairly%20new%20to%20powershell%20and%20trying%20to%20simplify%20some%20routine%20task%20to%20a%20few%20powershell%20scripts.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EBackground%3A%20on-prem%20AD%20to%20Office%20365%20sync%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EQuestion%3A%20If%20a%20user%20leaves%20a%20company%2C%20can%20I%20create%20a%20scripts%20to%20do%20following%3A%3C%2FP%3E%3CP%3E1)Reset%20user%20password%3C%2FP%3E%3CP%3E2)Remove%20user%20from%20all%20groups%3C%2FP%3E%3CP%3E3)Block%20user%20sign%20in%3C%2FP%3E%3CP%3E4)Convert%20mailbox%20to%20a%20shared%20mailbox%20and%20give%20delegated%20access%20to%20another%20user.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI'm%20new%20to%20this%20forum%20and%20not%20expecting%20anyone%20to%20help%20me%2C%20but%20if%20someone%20can%20please%20point%20me%20in%20the%20right%20direction%2C%20that'll%20be%20appreciated.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThank%20you%20in%20advance.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-1335758%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EActive%20Directory%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EOffice%20365%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1336014%22%20slang%3D%22en-US%22%3ERe%3A%20AD%20to%20Office%20365%20Powershell%20Commands%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1336014%22%20slang%3D%22en-US%22%3E%3CP%3EHave%20you%20tried%20doing%20a%20search%20online%3F%20I've%20seen%20quite%20few%20articles%20that%20go%20over%20the%20process%2C%20even%20provided%20scripts%20that%20address%20some%20of%20those%20tasks%20myself.%20Don't%20be%20lazy%20%3A)%3C%2Fimg%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E
Occasional Visitor

Hi,

 

I'm fairly new to powershell and trying to simplify some routine task to a few powershell scripts.

 

Background: on-prem AD to Office 365 sync 

 

Question: If a user leaves a company, can I create a scripts to do following:

1)Reset user password

2)Remove user from all groups

3)Block user sign in

4)Convert mailbox to a shared mailbox and give delegated access to another user.

 

I'm new to this forum and not expecting anyone to help me, but if someone can please point me in the right direction, that'll be appreciated.

 

Thank you in advance.

 

 

1 Reply

Have you tried doing a search online? I've seen quite few articles that go over the process, even provided scripts that address some of those tasks myself. Don't be lazy :)