Forcing anEXE created with Merge-Script to use either WInPS 5.1 or PWSH 7

How can I force the created executable to use either WIndows PS or PS Core, if both are avaiable in the executing PC.

Does it depend on the version of PS that executes the Merge-Script?

Please advise.

Hi Adam, I wonder if you can explain how this can be accomplished.