How can Invoke-WebRequest change ProgressBar?
Posted: Mon Feb 18, 2019 6:10 am
Hi
i am a beginner with PowerShell and a total beginner with PowerShell Studio
Product, version and build:
Powershell Studio 2019 5.6.159.0 64 bit
Operating system:
Win 10 64 Bit 1803
i am writing a powershell-program to download the newest version of my programm. i have to download one big EXE (=installation program)
in my powershell-program i check internet connection, if my program is available, if it is neccessary to download, and so on.
Everything works so far, but i am not able to fill the progress bar while downloading .
i have a form with a download-button. if this is clicked, i use Invoke-WebRequest to download the file i want. the file is downloading, but the progressbar shows always "0%".
i try $ProgressPreference = "SilentlyContinue" or not, no difference.
if i comment out $ProgressPreference, the compiled version shows nothing, but if i run it in PowerShell Studio, there is an other progressbar shown (this is default i mentioned).
What should i do?
i have no more ideas to try.
Best Regards
Klaus
i am a beginner with PowerShell and a total beginner with PowerShell Studio
Product, version and build:
Powershell Studio 2019 5.6.159.0 64 bit
Operating system:
Win 10 64 Bit 1803
i am writing a powershell-program to download the newest version of my programm. i have to download one big EXE (=installation program)
in my powershell-program i check internet connection, if my program is available, if it is neccessary to download, and so on.
Everything works so far, but i am not able to fill the progress bar while downloading .
i have a form with a download-button. if this is clicked, i use Invoke-WebRequest to download the file i want. the file is downloading, but the progressbar shows always "0%".
i try $ProgressPreference = "SilentlyContinue" or not, no difference.
if i comment out $ProgressPreference, the compiled version shows nothing, but if i run it in PowerShell Studio, there is an other progressbar shown (this is default i mentioned).
What should i do?
i have no more ideas to try.
Best Regards
Klaus