Results 1 to 10 of 10
  1. #1
    Silver Lounger
    Join Date
    Dec 2000
    Location
    California, USA
    Posts
    1,758
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Popup Object (XP)

    Is there an object that can be called to simulate the popup which appears in the bottom right corner when a new outlook message appears? It briefly appears and then goes away. I would like to try this in Excel.

    Thanks,
    John

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Popup Object (XP)

    You need to use Windows API calls for this. See the attached demo, based on this tip from Excel MVP Colo.
    Attached Files Attached Files

  3. #3
    Silver Lounger
    Join Date
    Dec 2000
    Location
    California, USA
    Posts
    1,758
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Popup Object (XP)

    Thank you Hans

    My search efforts were not returning what I was after.

    Regards,
    John

  4. #4
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Popup Object (XP)

    Slightly improved version attached.
    Attached Files Attached Files

  5. #5
    Silver Lounger
    Join Date
    Dec 2000
    Location
    California, USA
    Posts
    1,758
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Popup Object (XP)

    Hans,

    Great modification.

    Thanks,
    John

  6. #6
    Silver Lounger
    Join Date
    Jul 2001
    Location
    Ottawa, Ontario, Canada
    Posts
    1,609
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: Popup Object (XP)

    Hi Hans
    It's a bad day when you don't learn something. You have just ensured that my next day or two will be worthwhile.

    <img src=/S/thankyou.gif border=0 alt=thankyou width=40 height=15>
    Regards
    Don

  7. #7
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Popup Object (XP)

    Transparent windows are fun, but be careful. While experimenting with the workbook I attached, I managed several times to make the Visual Basic Editor semitransparent, which is disconcerting. And if you make a window fully transparent, it becomes invisible, which can be a nuisance. (I set the Min property of the scroll bar on the userform to 20 instead of 0 to prevent the user from making it completely invisible.)

  8. #8
    Silver Lounger
    Join Date
    Jul 2001
    Location
    Ottawa, Ontario, Canada
    Posts
    1,609
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: Popup Object (XP)

    Hi Hans

    It took me no time at all to realize what you meant by
    <hr>but be careful<hr>
    I don't relish the thought of pulling the power plug every time I attempt to step through the program.

    You don't any any chance have some recovery code which I could stick into Personal with a hot key; do you?
    Regards
    Don

  9. #9
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Popup Object (XP)

    You shouldn't try to single-step the code, just run it.
    The only negative effect I noticed was that occasionally, the wrong window became semitransparent, but this would either correct itself after a while, or when I quit and restarted Excel, so I don't know what you mean by recovery code.

  10. #10
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Popup Object (XP)

    The attached version uses a safer method to get the window handle of the userform - instead of GetActiveWindow, it uses FindWindow with the class name and caption of the userform.
    Attached Files Attached Files

Posting Permissions

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