question

rainmakers-3202 avatar image
0 Votes"
rainmakers-3202 asked rainmakers-3202 commented

Write-Progress only works on first Powershell ISE Tab

When working with Powershell ISE tabs, the Write-Progress only works on the first tab. Is there a way to enable it to work on all ISE tabs?

To duplicate the issue:

  1. open the ISE

  2. Paste the code snippet below in the first tab, and you will see the progress bar.

  3. goto File -> New PowerShell Tab

  4. goto the 2nd tab

  5. run the same code snippet below in the 2nd tab, and there will not be a progress bar.

Thanks in advance.

 For ($i=0; $i -le 100; $i++) {
 Start-Sleep -Milliseconds 20
 Write-Progress -Activity "Example"  -PercentComplete $i
 }



windows-server-powershell
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

RichMatheisen-8856 avatar image
0 Votes"
RichMatheisen-8856 answered rainmakers-3202 commented

If you close the 1st tab does it now work for the code in the other tab?

You should know that the PowerShell ISE is no longer a supported product. You'd do well to switch to something like VS Code or Visual Studio, or some other editor. Some folks like Notepad++.

· 1
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Closing the first tab did allow the progress bar to show.
Thanks for the update about the ISE. With the ISE being retired I doubt Microsoft would fix the functionality.

0 Votes 0 ·