Tuesday, 15 February 2011

How to get Outlook appointment reminders to pop up in front of other windows again using some simple VBA.

If you’ve got Windows 7 and Outlook, you may have noticed that the Outlook reminders window doesn’t pop up and steal focus any more… which means that if you’re an every window maximised kinda guy, then you don’t always notice the reminders anymore and sometimes miss meetings.
If you’ve not noticed, then you probably don’t think it’s a problem, and as it happens, this new behaviour is by design so that you don’t unknowingly dismiss the reminder window by hitting enter.
I prefer the new behaviour, but then I only really use Outlook at work and have it up in its own dedicated monitor there. Also, I'm not an every window maximised kinda guy.
If like several of my colleagues you want something like the old behaviour back, this is what I pulled out of my hatch for them - it's not elegant but you're welcome to try it and see if it works for you:


  • Create a Digital certificate for later
    • Hit Start and type ‘certificate’, select ‘Digital Certificate for VBA Projects’
    • Enter a name for your certificate
    • Done
  • Open Outlook and hit Alt + F11 to start the VBA editor.
  • In the tree on the left, expand ‘Microsoft Office Outlook Objects' and double click on ‘ThisOutlookSession’
  • Paste in this code, modifying the text in quotes to suit your preferences. Leave the quotes in.

Private Sub Application_Reminder(ByVal Item As Object)


    If TypeOf Item Is AppointmentItem Then
    MsgBox "Message text", vbSystemModal, "Message title"
    End If


End Sub

  • Sign the Macro so it will run by going to Tools > Digital Signature… and choosing the certificate you created earlier
  • Close the VBA window

This should work for most versions of Outlook. There may be better or more elegant ways of doing this and if anyone knows of one, please say so.

13 comments:

  1. Hello, firstly thanks for this great idea / workaround for the issue!

    However I have a problem with the Script as it only will run for a limited Time, it seems the script won't work after a reboot but it's still present in the VBA Editor.
    I have checked and allowed the Macro Security Settings in Outlook and allowed also, I also saw the used Certificate was not trusted and I put it int eh Trusted Root Certificate Folder... However the Script didn't work again.. and when I started my machine today from Sleep and had a Meeting in the morning it was working like a charm again. Does anyone seen this behavior too or might know an answer?

    ReplyDelete
  2. Great trick. I was looking for something like this not to miss my reminders. Thanks!

    ReplyDelete
  3. Well, that's certainly an improvement. Thank you for writing this and posting it!

    Where does Microsoft get off thinking they know what is best for every single user? Apparently "the rest" of us don't have giant multimonitor setups with amplified speakers like Microsoft employees have.

    The little blinking thing at the bottom of the screen doesn't even count as a reminder. Give us the *option* to make the popup actually POP UP, Microsoft.

    ReplyDelete
  4. Thanks so much! however, if I want to get rid of this certificate, how do I remove it?

    ReplyDelete
  5. This works great. FYI, at least in Outlook 2010, you can change the "MsgBox..." line to "Application.ActiveExplorer.Activate" and it will just activate the Outlook reminder instead of creating a message box which you also have to close.

    ReplyDelete
    Replies
    1. If that takes focus then it's an improvement, I'll give it a go.

      Delete
    2. i have put this code in and it doesnt seem to work please tell me if im doing something wrong

      Private Sub Application_Reminder(ByVal Item As Object)


      Rem If TypeOf Item Is AppointmentItem Then
      Application.ActiveExplorer.Activate"Message text", vbSystemModal, "Message title"

      End If


      End Sub

      Delete
  6. How can I make the pop-up reminder "blink" and "flash"? How can I change the colour to something much more vivid? Thanks

    ReplyDelete
    Replies
    1. Not sure how to decorate the message box, but 'vb decorate message box' is probably what you want to search for

      Delete
  7. Yes, the problem with this is when you reload outlook the script no longer works. It seems that outlook only allows you to create the Vba for the session that you wrote the script for. Help, can some bright spark please help. Thanks

    ReplyDelete
    Replies
    1. Should be sticky if you put it where I said and sign it but your sysadmin may have done policy stuff (actual technical term, honest) that blocks this kind of thing

      Delete