i am trying to make a file in javascript, but it doesn't be saved in the root. when the file is made, the sentence i write has to be stored in the file. or loading a sentence from a textbox is also fine for me. can anyone give me help??
function createFile() {
var fso = new ActiveXObject('Scripting.FileSystemObject');
var fileObj = fso.CreateTextFile("G:\\soonrok.txt", true);
fileObj.WriteLine("Hello, I am Soonrok!!!");
}
<td>
<input type="button" value="save" onClick="createFile()">