Friday, 2 August 2019

"Open File" Dialog

Migrating uses between Skype for Business and Skype Online lately and have been migrating in batches/pilot groups.

Having gotten sick of upding the filename or file location in the powershell script, i went searching and found a nice article on how to create a open file dialog box.

I'm sure there is a better/easier to complete, but this worked for me.
$connect = Read-host "Connect to O365 Skype Online: [Y|N]?"
if($connect -like "Y")
Import-Module SkypeOnlineConnector
$userCredential = Get-Credential
$sfbSession = New-CsOnlineSession -Credential $userCredential
Import-PSSession $sfbSession
if($userCredential.UserName -eq $nul)
write-host "No Crediential Set for move" -ForegroundColor Red

write-host "connected user"

$openChooser = New-Object -TypeName System.Windows.Forms.OpenFileDialog
$fileimport = import-csv $openChooser.FileName
foreach($i in $fileimport)
write-host -ForegroundColor Cyan $i.displayname -NoNewline
write-host " is currently being migrated"


M365 Call Flow Visualizer

This is a port so that I remember where to find the scripts.. Shout out to the author: ...