$originalLocation = Get-Location $scriptPath = Split-Path -Parent $MyInvocation.MyCommand.Path Set-Location $scriptPath $exePath = "..\build\bin\butck_gui.exe" if (Test-Path $exePath) { & $exePath } Set-Location $originalLocation