Execute a system command: Difference between revisions

Content added Content deleted
(Added unix function/statement in F 7.0.23)
m (→‎{{header|FutureBasic}}: Add 'print' to FB 7.0.23 entry. Remove 'dim as' from open unix entry)
Line 692: Line 692:
FB 7.0.23+
FB 7.0.23+
<syntaxhighlight lang="futurebasic">
<syntaxhighlight lang="futurebasic">
unix (@"ls -A")
print unix(@"ls -A")
</syntaxhighlight>
</syntaxhighlight>
Classic FB using Pascal strings
Classic FB using Pascal strings
<syntaxhighlight>
<syntaxhighlight>
local fn DoUnixCommand( cmd as str255 )
local fn DoUnixCommand( cmd as str255 )
dim as str255 s
str255 s


open "Unix", 2, cmd
open "Unix", 2, cmd