$tempfile = "C:\temp\inmemory-exec.txt"; "Hello from memory" | out-file -filepath $tempfile;