Nasal library/io: Difference between revisions

Jump to navigation Jump to search
→‎close(): Add example
(Add variables, start to doc close())
(→‎close(): Add example)
Line 24: Line 24:
|param1 = path
|param1 = path
|param1text = Path as a string.
|param1text = Path as a string.
|example1 =  
|example1 = var path = getprop("/sim/fg-root") ~ '/keyboard.xml';
var file = io.open(path);
print(io.readln(file)); # prints the XML header
io.close(file);
}}
}}


Navigation menu