Results 1 to 3 of 3

Thread: outlooks Application_startup event doesn't always fire

  1. #1

    Thread Starter
    Super Moderator FunkyDexter's Avatar
    Join Date
    Apr 2005
    Location
    An obscure body in the SK system. The inhabitants call it Earth
    Posts
    7,957

    outlooks Application_startup event doesn't always fire

    I found something rather odd today while playing around in outlook and I wondered if anyone else had experienced it and/or knew what caused it. I wanted to create an outlook.application object with events when outlook starts. As far as I know this should have done it:-

    Public WithEvents outlook As Application

    Private Sub Application_Startup()
    Set outlook = CreateObject("Outlook.Application")
    End Sub

    I noticed, though, that some of my events weren't firing. I added a megbox as the first command of the startup event and discovered it was only firing a fraction of the time (so the events I wrote for outlook were in turn not firing).

    A colleague tells me that sometimes outlook doesn't actually close when it appears to so maybe when I restarting I wasn't really starting the app but was 'waking it up'. I don't think that's the reason though because even a after a full reboot the startup event just doesn't fire sometimes.

    I've already found get arounds to do everything I want but I was curious to see if anyone knew anything about this as I'm sure it'll trouble me again sooner or later.

  2. #2
    Don't Panic! Ecniv's Avatar
    Join Date
    Nov 2000
    Location
    Amsterdam...
    Posts
    5,343

    Re: outlooks Application_startup event doesn't always fire

    No idea ... possibly some sort of security is stopping the code?

    You'd have to make a module of all the events, and debug.print them to the immediates window. Save n close. Restart and see which fire. close and restart the app, see what happens.

    Possibly windoze/ms did something to hold it in the background, or running under something else. Who knows (ms?) Have a go and see what happens. Maybe it is something which only fires once per day, and once ran it thinks it doesn't need to re-run it...

    BOFH Now, BOFH Past, Information on duplicates

    Feeling like a fly on the inside of a closed window (Thunk!)
    If I post a lot, it is because I am bored at work! ;D Or stuck...
    * Anything I post can be only my opinion. Advice etc is up to you to persue...

  3. #3

    Thread Starter
    Super Moderator FunkyDexter's Avatar
    Join Date
    Apr 2005
    Location
    An obscure body in the SK system. The inhabitants call it Earth
    Posts
    7,957

    Re: outlooks Application_startup event doesn't always fire

    Bizarre, the startup event now seems to be firing every time. I think a gremlin's laughing at me from inside my laptop.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width