I am trying to set an icon for my wscript.shell. Not the notification icon, but the actual form icon, where the title bar is. Icon is not one of the properties, so is this even possible? It seems like it should be, but I am stumped. Can an icon be added to the popup? I am adding my code and an image showing my output. Thanks for any help
Set-StrictMode -Version latest
function monitorProcesses{
DO{
foreach($name in $processList){
if((Get-Process $name -ErrorAction SilentlyContinue) -eq $null){
#fill our finished processes list
if($finishedList -notcontains($name)){
$finishedList.Add($name) | Out-Null
}
}
}
}while($finishedList.Count -ne $processList.Count)
$tracker.Popup("All startup processes have completed. It is safe to start the program", 10, "All Processes Complete", 0 + 4096 + 64) | Out-Null
}
#____________________________________ Main ____________________________________#
#create initial list and empty finished list
$processList = @('WINWORD', 'msedge')
[System.Collections.ArrayList]$finishedList = @()
$tracker = New-Object -ComObject Wscript.Shell
$tracker.Popup("Please wait for all startup processes to end before starting the program", 10, "Please Wait", 0 + 4096 + 48) | Out-Null
monitorProcesses