I want to first check to see if the specified file is created, if so delete it and then put the contents of my string (simple xml document built using string manipulations into a text file and save as an xml extension. If tried this code:
Nothing seems to be happening but I'm sure this code can be improved. Any pointers and hints would be greatly appreciate.
Thanks,
Rewdee
Code:
dim fso, TextFile
set fso = createobject("Scripting.FileSystemObject")
set TextFile = objfso.createtextfile("c:\temp.xml")
On Error Resume Next
TextFile.Delete
set TextFile = objfso.createtextfile("c:\temp.xml")
TextFile.writeLine(sXML)
TextFile.Close
Thanks,
Rewdee