Hey there @leandermw , Welcome to the HP Forums
I understand you're having scanning problem with your Deskjet 2540, on Windows 8.1 and would like to help you.
I would first suggest that you run the Print and Scan Doctor, and choose "fix scanning" to see if the tool can correct the issue. Send me the results in your reply as well.
If you have the printer connected to a network, either wireless or ethernet, try power cycling the network devices:
Turn off the printer and computer and unplug the router for 1 minute (do not press any buttons on the router).
Plug the router back in and wait another minute, next turn on the printer and computer and try scanning.
You can also power reset the printer itself:
Press the Power button to turn on the product.
With the product turned on, disconnect the power cord from the rear of the product.
Unplug the power cord from the wall outlet.
Wait at least 15 seconds.
Plug the power cord back into the wall outlet.
Reconnect the power cord to the rear of the product.
If the product does not turn on by itself, press the Power button to turn it on.
Ensure the printer is plugged in directly to the wall outlet, avoiding power bars and surge protectors. This ensures the printer is receiving full power and may help greatly.
Try scanning from the HP scan software on your computer, and also make a copy from the front of the printer.
Write me back with the results
ℜ a i n b o w 7000
I work on behalf of HP
★
Click the “Kudos Thumbs Up" at the bottom of this post to say “Thanks” for helping!