Get-AzureADUser -SearchString user1@xyz | Get-AzureADUserMembership -All $true | % {Get-AzureADObjectByObjectId -ObjectId $_.ObjectId | select-object DisplayName,Mail,ObjectType,MailEnabled,SecurityEnabled,ObjectId} | Export-Csv -Path 'C:\new_folder\UserDetails.csv'
Showing posts with label Active Directory. Show all posts
Showing posts with label Active Directory. Show all posts
Convert GUID to Immutable ID
[Convert]::ToBase64String([guid]::New("531dbe80-43f0-4d7b-bab0-148b84bf84cb").ToByteArray())
Access AD without installing RSAT
Access AD without installing RSAT
Open in Run -
C:\Windows\System32\rundll32.exe dsquery.dll,OpenQueryWindow
Get group member / user Email and City
Get group member / user Email and City
Get-ADGroupMember -Identity "Group Name" -Recursive | Get-ADUser -Properties Mail,city | Select-Object Name,SamAccountName,Mail,city | Export-CSV -Path C:\Newfolder\NEW.csv -NoTypeInformation
==============================================================
Get-ADUser -Filter "City -eq 'CityName'"
Extract Group Policy Report
Extract Group Policy Report
-----------------------------------------------------------------
Command-
cd desktop <Press enter>
GPRESULT /H GPReport.html <Press enter>
GPReport.html <Press enter>