im trying to make a desktop gui used node.js to execute my program ,i want to know if there have anyway to create a click button to execute pe(exe) file use node.js and html? (my english not really good hope you can understand :)
            Asked
            
        
        
            Active
            
        
            Viewed 322 times
        
    -2
            
            
        - 
                    Please clarify. You want something in a browser to run a native executable? If so, this is a duplicate: https://stackoverflow.com/q/20643470/1531971 – Nov 01 '18 at 15:57
1 Answers
1
            
            
        Take a look at the following sample code :
const { exec } = require('child_process');
exec('cat *.js missing_file | wc -l', (error, stdout, stderr) => {
  if (error) {
    console.error(`exec error: ${error}`);
    return;
  }
  console.log(`stdout: ${stdout}`);
  console.log(`stderr: ${stderr}`);
});And read here carefully : https://nodejs.org/docs/latest/api/child_process.html
 
    
    
        Ashouri
        
- 906
- 4
- 19
