I am very new to programming. I started about 1 month ago. I am currently stuck on an issue with saving data from an SQL table into a local text file (exporting of some sort).
I have no problem connecting to the SQL database (reading, writing, etc.) but when I attempt to write anything to a text file, it doesn't work.
With this code, I get a path not found error.
set textDB = Server.CreateObject("Scripting.FileSystemObject"
set rsText = textDB.OpenTextFile("C:\Inventory\Inventory.txt",8,TRUE)
rsText.WriteLine("This is a test..."
rsText.Close
The page resides on a web server at work and I am attempting to save the file on my local c: drive. There is a directory called Inventory on my C: drive (and I have tried putting an empty Inventory.txt file in it as well).
Is it trying to save the file to the server? What am I doing wrong?
Thank you in advance for your help!
I have no problem connecting to the SQL database (reading, writing, etc.) but when I attempt to write anything to a text file, it doesn't work.
With this code, I get a path not found error.
set textDB = Server.CreateObject("Scripting.FileSystemObject"
set rsText = textDB.OpenTextFile("C:\Inventory\Inventory.txt",8,TRUE)
rsText.WriteLine("This is a test..."
rsText.Close
The page resides on a web server at work and I am attempting to save the file on my local c: drive. There is a directory called Inventory on my C: drive (and I have tried putting an empty Inventory.txt file in it as well).
Is it trying to save the file to the server? What am I doing wrong?
Thank you in advance for your help!