Is there a way to stream or write a file from a server to client PC?
String filename = "download.txt";
String webPath = "C:\\download\\";
File file = new File(webPath+filename);
FileWriter fileWrite = new FileWriter(file);
String outputString = new String();
outputString += "Text here";
outputString += "and here";
fileWrite.write(outputString);
fileWrite.flush();
fileWrite.close();
I get the following error:
java.io.FileNotFoundException: C:\download\download.txt(The system cannot find the path specified)
String filename = "download.txt";
String webPath = "C:\\download\\";
File file = new File(webPath+filename);
FileWriter fileWrite = new FileWriter(file);
String outputString = new String();
outputString += "Text here";
outputString += "and here";
fileWrite.write(outputString);
fileWrite.flush();
fileWrite.close();
I get the following error:
java.io.FileNotFoundException: C:\download\download.txt(The system cannot find the path specified)