Thanks for pointing this out. I've modified the Wiki page.
http://www.freebasic.net/wiki/wikka.php ... KeyPgChdir
If you find any more errors, don't be afraid to create a Wiki account for changing such things yourself.
With the Pipe example, I think the command text, at least in Windows, is in the format you'd type it into a command prompt. This allows you to add additional parameters, or type non-executable commands. e.g.
Code: Select all
Dim text As String
Open Pipe "dir" For Input As #1
Print "Output of dir:"
Do Until Eof(1)
Line Input #1, text
Print text
Loop
So, for path names with spaces, you could try enclosing it in quotes (note that two double-quotes ("") in a string gives a double-quote for you)
Code: Select all
Dim text As String
Open Pipe """C:\program files\FreeBASIC\fbc.exe""" For Input As #1
Print "Output of fbc:"
Do Until Eof(1)
Line Input #1, text
Print text
Loop