Run powershell script (batch file) from another powershell script
I found out, it dependes, if we are running powershell script from powershell ISE or powershell console.
When I need to call prepinac.ps1, or hop.bat from MasterScript.ps1..
for PS console use in MasterScript.ps1, (run as .\MasterScript.ps1 in console)
for PS ISE - use in MasterScript.ps1 it's the same for running script F5, or to type it to PS command line.
if you use .\prepinac.ps1, error message is displayed. You have to change location to script directory.