Task

Demonstrate the language's ability to include source code from other files.




See Also
 Compiler/Simple file inclusion pre processor




 
Include "D:\include\pad.vbs"
 
Wscript.Echo lpad(12,14,"-")
 
Sub Include (file)
   dim fso: set fso = CreateObject("Scripting.FileSystemObject")
   if fso.FileExists(file) then ExecuteGlobal fso.OpenTextFile(file).ReadAll
End Sub
 