Very rarely can you do a foolproof practical joke.
The one played on me involved hiding small diameter plastic in a power supply I had designed and was testing. I had gone to lunch, and when I came back and turned it on, smoke started rising out of it. I turned it off, the smoke went away. So I went looking for what had failed. Failing to find any failure, I turn it on again with exactly the same results.
Of course, after a few times of doing this, the guys on the bench opposite me could not stop laughing. This was in the days when you could smoke on the job, and they were blowing cigarette smoke at appropriate times through the tube. And...all the while I also would get expressions of concern and offers of help to resolve the problem from the very instigators of the joke.
At the start of win 3.0 I did a print screen on my bosses pc, pasted the picture into paintbrush and displayed it full screen. After watching him furiously click on the image and curs he finally just turned the pc off. The next day while talking to him I showed him some Key board short cuts like closing an application by holding the Alt key and pushing the F4 key or changing applications by holding the Alt key and pressing the Tab key. The pore guy never knew what had happened.
I too played a joke on a guy at work many years ago. When you tried to boot DOS with a data floppy, you would get an error like ""disk boot failure, insert system disk and press enter". I changed the BIOS to boot from his 2nd hard drive to get that error. And I change Autoexec.bat to print out that message too. I also changed config.sys to point to an alternate Autoexc file all printing out that error message. He is a very smart guy but with 5 different failures all displaying the same message, he was ... frustrated. After a few hours I helped him out. I do recall that he did get even.
After watching the escalation of some "practical" jokes in my department a few years ago I decided to not even let on that I saw them, in hopes of not getting into the contest. What did lead to an end of the tricks was somebodies creative mechanism that dumped a whole quart of water on a tech while the manager was standing there talking to him. Not only was he soaked, but the boss got wet as well. That was the end of the games.
What was more interesting was when Timbuktu allowed desktop control by a remote user... A group of snickering people huddled around a computer in the adjacent cubicle whilst the victim cursed and beat his computer....
That's clever. I did one once on an accounts guy at a travel agent I used to do work for. This guy thought he was a bit superior to all the others. Eventually he left and before he went the staff asked me to do something to his PC. I didn't have much time so I put a batch file in his autoexec.bat, which announced that it was the "teacher" virus and that he had to type out "I am an idiot" 100 times within 5 minutes, else it would wipe his hard disk. He fell for it, and the staff went in to ask him silly questions while he was feverishly typing away, just to annoy him. They said it was hilarious. The silly thing was, if he'd just pressed Ctrl-C he would have stopped it!
He got his revenge....before he went he swapped around all the connectors on my terminal controller.
Back in the early 80s we were designing a scanning laser ophthalmoscope. My physicist had left the 1 mw laser on while going to lunch and had the beam hitting a note card. While he was at lunch I took the card and burned a hole where the beam had been hitting the card with a match, then carefully placed the card back where the guy had left it. When my physics friend came back from lunch he looked at the card and quickly turned off the laser. I couldn't help laughing giving it away too quickly.
This reminds me of the early "Timbuktu" days where you could control someones desktop remotely and they could see it (late 80s). A coworker and I decided to demonstrate our voice operated user input technology to our boss. Teh coworker was in the next cubicle and our boss was very impressed with how well my voice commands were carried out. However, he was dismayed by the fact that the computer was completely unresponsive to his voice. I suggested that it was because it was setup to respond to male voices and that he should try to talk in a lower tone. Eventually the giggling in the next cubicle gave it away...