Posts

Showing posts from July, 2021

Microsoft Teams. Thêm đồng thời nhiều member vào team

Microsoft Teams. Thêm đồng thời nhiều member vào team Phần 1. Chuẩn bị máy 1. Chạy PowerShell với quyền quản trị 2. Thực thi câu lệnh  Install-Module -Name MicrosoftTeams . Nhiều khả năng là sẽ được yêu cầu cài đặt NuGet. Chấp thuận cài đặt NuGet để tiếp tục. 3. Đóng cửa sổ PowerShell 4. Chạy PowerShell với quyền người dùng bình thường. 5. Thực thi lần lượt các câu lệnh: Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope Process Import-Module MicrosoftTeams Connect-MicrosoftTeams 6. Tạo script để thêm member (dùng trình soạn thảo bất kỳ). Tạm gọi tên script là "mst-bulkuseradd.ps1". Nội dung như sau: Write-Host "Starting the script..." $FILE_LOCATION = Read-Host -Prompt 'Enter the path to the emails csv file' $GROUP_ID = Read-Host -Prompt 'Input Group ID' $USER_TYPE = Read-Host -Prompt 'User Type(Owner/Member)' $USER_EMAILS = Import-Csv -Path "$FILE_LOCATION" foreach ($email in