There is a missing "}" in this script, which is opened on line 15:
If (!(Test-Path "$env:ProgramFiles\Rustdesk\RustDesk.exe")) {
so please add the bracket where should be.
And another thing is unclear for me:
On line 9 there is a comment which is containing the DNS/IP and the public key of the rustdesk server, but they're never used in the powershell script, why? Maybe you can also comment a little bit to know whats going on in this script, there are several service start/stop commands, which are all executed at the same time, maybe you deleted a few rows accidentally.
There is a missing "}" in this script, which is opened on line 15:
If (!(Test-Path "$env:ProgramFiles\Rustdesk\RustDesk.exe")) {
so please add the bracket where should be.
And another thing is unclear for me:
On line 9 there is a comment which is containing the DNS/IP and the public key of the rustdesk server, but they're never used in the powershell script, why? Maybe you can also comment a little bit to know whats going on in this script, there are several service start/stop commands, which are all executed at the same time, maybe you deleted a few rows accidentally.