You can echo the real spaces using /loadbuf -e (evaluation). Put the spaced string in a %variable. Put the name of the %variable on its own in the file (this way, you can reuse the file and don't have to write to the disk every time). Then use /loadbuf with the evaluation switch to echo it.

I know, this doesn't solve the problem of getting the spaces in an on input event. smirk