Basic security doesn't permit you to do this but, it possible to instantiate the FileSystemObject on the client side with IE and write files on the client's machine. Thankfully, there is a security warning.
var fso = new ActiveXObject("Scripting.FileSystemObject");
var a = fso.CreateTextFile("c: estfile.txt", true);
a.WriteLine("This is a test.");