Forum Discussion

tcuser3's avatar
tcuser3
Occasional Contributor
5 years ago
Solved

Running TestExecute from Powershell - TestExecute.exe is not a valid project.

Hi all I'm using TestExecute 14.10.1042.11 x86 with Windows 10 1903 build 18362.295.  When opening powershell (32 or 64 bit) and calling testexecute.exe I awlays get:   Cannot open "C:\Progra...
  • VladYatskovskiy's avatar
    5 years ago

    Hello. If you look at actual command line of launched process you will see:
    "C:\PROGRA~2\SMARTB~1\TESTEX~2\Bin\TESTEX~1.EXE" "C:\Program Files (x86)\SmartBear\TestExecute 14\Bin\TestExecute.exe"
    That's where source of the error lies -- PowerShell transfers full path to TestExecute.exe as the first command line argument of the created process.
    Best way to launch some executable from PowerShell script is to use Start-Proccess cmdlet.
    You may take a look at this usefull arcticle about launching processes form PowerShell:
    https://social.technet.microsoft.com/wiki/contents/articles/7703.powershell-running-executables.aspx#Start-Process_start_saps