Thanks, Catalin.
I do use the 'attached script' in some places and 'inline PS script' in other places.
The thing is that the inline PS script sources the temporary file via the dot operator.
$script = $param
. $script
# some PS code before calling a function from the temporary PS script file ...
FOLLOW US