Questions tagged [robotjs]

RobotJS is a desktop automation library

RobotJS is a desktop automation library with support for Mac, Windows and Linux.

40 questions
5
votes
2 answers

Node-Windows - Run GUI app on Logon screen

I need to run a GUI app on the logon screen on Windows 7 to 10. I have a nodejs app registered as a service which runs as SYSTEM (the default), using node-windows module. This seems to be a prerequisite to what I need, but something more is…
jdmayfield
  • 1,400
  • 1
  • 14
  • 26
4
votes
1 answer

Is there anything similar to PyAutoGUI for NodeJS that can try to locate an image inside a screen capture?

I am trying to code a bot to automate some tasks on a videogame with JS and Node, so far I've been using RobotJS. The problem I'm facing is that I need to find something on the screen as it moves from time to time to then click on it. Something…
Oscar Arranz
  • 631
  • 2
  • 9
  • 23
4
votes
0 answers

Node Module (robotjs) was compiled against a different Node.js version

So I'm trying to build a simple VS Code extension but after I finally found the right modul to use I can't get it to run corectly. After pressing F5 to test the extension i just get the message: Activating extension…
felixkoe
  • 65
  • 1
  • 4
3
votes
0 answers

Which versions, if any, of robotjs and electronjs are compatible?

Within an Electron project I just tried requiring RobotJS and got the error: Uncaught Error: The module '\\?\C:\Users\\... snip ...\app\bot\node_modules\robotjs\build\Release\robotjs.node' was compiled against a different Node.js version…
J.Todd
  • 707
  • 1
  • 12
  • 34
2
votes
2 answers

robotjs npm install ERROR: gyp ERR! (Ubuntu 20.04)

I have node.js installed and I have tried various commands and installations but I keep getting a weird error when trying to do npm install robotjs So this is the error root@name-VirtualBox:/home/name/Desktop# npm install robotjs npm ERR! code…
2
votes
1 answer

Random mouse movement between 2 coordinates?

Me and my friend made a game and we are trying to create a bot for it. Its repeating the same action over and over again. But the mouse always follows the same path from point A to point B. Is there a way to make the mouse move from point A to point…
Rick
  • 21
  • 1
2
votes
2 answers

Node - was compiled against a different Node.js version using NODE_MODULE_VERSION 72

I am working on a node application. Where I have to work with robotjs. When I tried to install the package to my node app, I am getting some error. Activating extension 'x' failed: The module '\\?…
Amjad
  • 330
  • 7
  • 22
2
votes
1 answer

TestCafe with Electron: show and hide main window

Our Electron application starts minimized to the Windows notification area i.e. not visible on the desktop. The user forces the app to display on the desktop by clicking on the app notification tray icon. Automating this is possible with RobotJs…
Maximojo
  • 315
  • 5
  • 17
1
vote
1 answer

I can't include the RobotJS module in my ElectronJS project

I am developing a desktop application for Windows using ElectronJS. I want to include the RobotJS module in my project, but I can't seem to figure out how to do it. I successfully downloaded the module by running 'npm install robotjs' and called it…
1
vote
1 answer

Javascript RobotJS colorAt function only working on one window

I have a JavaScript script that uses robotJS to find the color of pixels on the screen. I have created a test function that uses the current position of the mouse to read the color of pixels and display them to the console as hexadecimal. It seemed…
1
vote
1 answer

Robot.js tap key non-synchronously

I'm working with the package robot.js and need to run lots of key tap commands (often over 50 a second) with my program. So far it goes a bit like this: ...for in elements setTimeout(() => { console.log(element.deltaTime) // Logs the time that…
codingmaster398
  • 249
  • 4
  • 14
1
vote
1 answer

Electron/Webpack not reading .node files

Im trying to load robotjs with electron but I keep getting an annoying Failed to compile error. I'm using Vue.js for the interface, if that matters. The error error in ./node_modules/robotjs/build/Release/robotjs.node Module parse failed:…
Leonardo Bezerra
  • 668
  • 1
  • 10
  • 20
1
vote
0 answers

RobotJS, how to perform a shift click or command click on Mac?

I want to do perform a mouse click while holding down the shift key on Mac. I tried the following: robot.keyToggle('shift', 'down'); robot.mouseClick(); However it doesn't work. The mouseClick() registers as a click with holding down shift. How do…
Valachio
  • 1,025
  • 2
  • 18
  • 40
1
vote
0 answers

How do I test keyboard shortcuts (globalShortcut)?

I want to write integration tests for global keyboard shortcuts in electron. My app has some webviews with the functionality of zoom in/out to be tested using cmd= and cmd- keys respectively. I have tried several testing frameworks like spectron,…
coda
  • 2,188
  • 2
  • 22
  • 26
1
vote
0 answers

Electron-builder(electron notarize) - No suitable image -MacOS

I am using iohook module, in the local build its working fine ,For production build distribution after Mac notarize it's not working its saying no suitable image found any solution, please Issue
1
2 3