Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
12
Task/Write-entire-file/VBScript/write-entire-file.vb
Normal file
12
Task/Write-entire-file/VBScript/write-entire-file.vb
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
Set objFSO = CreateObject("Scripting.FileSystemObject")
|
||||
|
||||
SourceFile = objFSO.GetParentFolderName(WScript.ScriptFullName) & "\out.txt"
|
||||
Content = "(Over)write a file so that it contains a string." & vbCrLf &_
|
||||
"The reverse of Read entire file—for when you want to update or create a file which you would read in its entirety all at once."
|
||||
|
||||
With objFSO.OpenTextFile(SourceFile,2,True,0)
|
||||
.Write Content
|
||||
.Close
|
||||
End With
|
||||
|
||||
Set objFSO = Nothing
|
||||
Loading…
Add table
Add a link
Reference in a new issue