Hello. Is it possible to run the ncpa.cpl script in Windows using the Electron framework?

  • There is a suspicion that the answer is closely related to child_process and %windir%\system32\ncpa.cpl - Konstantin

2 answers 2

 var child = require('child_process').exec; var executablePath = "C:\\Windows\\system32\\ncpa.cpl"; child(executablePath, null, function(err, data) { console.log(err) console.log(data.toString()); }); 

    Using the power of Node.js

     const exec = require('child_process').exec; exec('control ncpa.cpl', (err, stdout, stderr) => { if (err) { console.error(err); return; } console.log(stdout); });