Errors while running ps1 file

Oct 12, 2015 at 6:57 AM
Hello, I got following errors when I entered the command ".\SPSWakeUP.ps1 .\SPSWakeUP.xml"

At E:\wakeup\2.0\SPSWakeUP.ps1:792 char:6
  • Return $Results
  • ~~~~~~~~~~~~~~~
    Flow of control cannot leave a Finally block.
    • CategoryInfo : ParserError: (:) [], ParseException
    • FullyQualifiedErrorId : ControlLeavingFinally
Coordinator
Dec 16, 2015 at 10:37 AM
I fix this issue, since Powershell 3.0 we cannot put a return in Try, Catch, Finally block.
You can download the new version 2.1.0, the fix is included.

Thanks for your help.
Marked as answer by Luigilink on 12/16/2015 at 3:40 AM