Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

copy file javascript

//copyfile.js
const fs = require('fs');

// destination will be created or overwritten by default.
fs.copyFile('C:folderAmyfile.txt', 'C:folderBmyfile.txt', (err) => {
  if (err) throw err;
  console.log('File was copied to destination');
});
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #copy #file #javascript
ADD COMMENT
Topic
Name
4+6 =