Fun Times with Colleagues

Buff
Buff Registered Posts: 275 Dedicated contributor πŸ¦‰
Have you ever wanted to annoy someone who you sit with, maybe just as a prank or a long term thing (which is very easy to do and to reverse)?

If they use Excel and leave a workbook open, right click on the sheetname on the tab at the bottom of the screen and click "View Code" (or alternatively you can hit Alt+F11

Copy the following code and paste it in the screen that comes up and then press the cross to close that screen.
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Selection.Interior.ColorIndex = Int((56 * Rnd) + 1)
End Sub

Whenever a cell is selected anywhere on the sheet, it is filled with a random colour :-)

To remove it, view the code and delete it and press the cross to close the screen again.

It'll have them scratching their heads for ages!

:lol::lol::lol:

Comments

  • AdamR
    AdamR Registered Posts: 668 Epic contributor 🐘
    Buff wrote: Β»
    Have you ever wanted to annoy someone who you sit with, maybe just as a prank or a long term thing (which is very easy to do and to reverse)?

    If they use Excel and leave a workbook open, right click on the sheetname on the tab at the bottom of the screen and click "View Code" (or alternatively you can hit Alt+F11

    Copy the following code and paste it in the screen that comes up and then press the cross to close that screen.
    Private Sub Worksheet_SelectionChange(ByVal Target As Range)
    Selection.Interior.ColorIndex = Int((56 * Rnd) + 1)
    End Sub
    

    Whenever a cell is selected anywhere on the sheet, it is filled with a random colour :-)

    To remove it, view the code and delete it and press the cross to close the screen again.

    It'll have them scratching their heads for ages!

    :lol::lol::lol:


    I like that!
  • Gem7321
    Gem7321 Registered Posts: 1,438 Beyond epic contributor πŸ§™β€β™‚οΈ
    Nice one! :001_smile:
  • AdamR
    AdamR Registered Posts: 668 Epic contributor 🐘
    Are you snowed in, Gem? Looks pretty bad in Exeter according to BBC News! Or did it all somehow miss you?:lol:
  • Gem7321
    Gem7321 Registered Posts: 1,438 Beyond epic contributor πŸ§™β€β™‚οΈ
    All melted now, but it wasn't that bad to begin with. It's so unfair :( the last time we had snow it was crap as well, we had it bad for one day then it melted
  • AdamR
    AdamR Registered Posts: 668 Epic contributor 🐘
    I was fed up of it by the 3rd day last time. Took two weeks for the last bit of ice to melt in my carpark. If it hadn't have rained, I think it would still be there!:laugh:

    It's laughable how we grind to a halt though - we could cope 40 years ago, we've had incredible advances in technology since then and yet we're going backwards!
  • AdamR
    AdamR Registered Posts: 668 Epic contributor 🐘
    And before I get shouted at, I apologise for hijacking this thread!:blushing::lol:
  • Buff
    Buff Registered Posts: 275 Dedicated contributor πŸ¦‰
    Euro-gazillions

    blank
  • Gem7321
    Gem7321 Registered Posts: 1,438 Beyond epic contributor πŸ§™β€β™‚οΈ
    I love snow, we didn't even have time to build a snowman last time! :(

    Yeah sorry J... *does the angelic look*
  • Paul24
    Paul24 Registered Posts: 578 Epic contributor 🐘
    AdamR wrote: Β»
    we could cope 40 years ago, we've had incredible advances in technology since then and yet we're going backwards!

    Thats part of the problem, werent so many cars about back then!
  • Gem7321
    Gem7321 Registered Posts: 1,438 Beyond epic contributor πŸ§™β€β™‚οΈ
    8!
  • Gem7321
    Gem7321 Registered Posts: 1,438 Beyond epic contributor πŸ§™β€β™‚οΈ
    Jamie I look like a knob now :ohmy:
  • Buff
    Buff Registered Posts: 275 Dedicated contributor πŸ¦‰
    only NOW?....

    ** heheh ** xx
  • AdamR
    AdamR Registered Posts: 668 Epic contributor 🐘
    Paul24 wrote: Β»
    Thats part of the problem, werent so many cars about back then!

    Not just cars though. Go on You Tube and search "Snow (1963)", you'll see what I mean.
  • mark130273
    mark130273 Registered Posts: 4,234 Beyond epic contributor πŸ§™β€β™‚οΈ
    Buff , that is evil..................but will it work on lotus ?
  • Buff
    Buff Registered Posts: 275 Dedicated contributor πŸ¦‰
    Mark,

    I don't think it will - VBA is a Microsoft built in editing language, which I am not sure if Lotus can use - if it can I'm not sure how to get to the code input screen (I guess you could try the same hot key Alt+F11 and see if that brings it up)

    I only really work with excel VBA so I couldn't comment on if it would work / delete data etc on other platforms.
  • mark130273
    mark130273 Registered Posts: 4,234 Beyond epic contributor πŸ§™β€β™‚οΈ
    ok thanks anyway.have to go to my old works and put it on there comp....now that would be so funny !!
Privacy Policy