ItemEvents_10_OpenEventHandler does not respond on DocumentItems

Status
Not open for further replies.
M

mightyCoCo

Hi,

I'm using the ItemEvents_10_OpenEventHandler to catch a open (double-

click) event on a Outlook item.

This works great on MailItem or PostItem types. However, Outlook

objects of the type DocumentItem dosen't seem to fire this event.

Instead I'm directly presented wih the document in it's native

application.

Is this a known restriction?

(Outlook 2007, VS2005)

thanks in advance,

-coco
 
According to the documentation the Open() event will fire if the

DocumentItem is opened in an Inspector. If it's not opened in an Inspector

but only in it's native application I wouldn't expect that event to work.

Check the count of the Inspectors collection before and after opening one of

these items and see if a new Inspector has been added to the collection. If

it has a workaround might be to handle NewInspector() and then check for

Inspector.CurrentItem.Class in that event handler. DocumentItem supports the

Class property and if the return from that is OlObjectClass.olDocument (41)

then you know a DocumentItem is being opened.

"mightyCoCo" <mightycoco@googlemail.com> wrote in message

news:802ee580-a7cf-48c1-9b13-24f9b272f4fa@r38g2000yqn.googlegroups.com...
> Hi,

> I'm using the ItemEvents_10_OpenEventHandler to catch a open (double-
> click) event on a Outlook item.
> This works great on MailItem or PostItem types. However, Outlook
> objects of the type DocumentItem dosen't seem to fire this event.
> Instead I'm directly presented wih the document in it's native
> application.

> Is this a known restriction?
> (Outlook 2007, VS2005)

> thanks in advance,
> -coco
 
On Jul 29, 4:33 pm, "
<kenslo...@mvps.org> wrote:
> According to the documentation the Open() event will fire if the
> DocumentItem is opened in an Inspector. If it's not opened in an Inspector
> but only in it's native application I wouldn't expect that event to work.

> Check the count of the Inspectors collection before and after opening oneof
> these items and see if a new Inspector has been added to the collection. If
> it has a workaround might be to handle NewInspector() and then check for
> Inspector.CurrentItem.Class in that event handler. DocumentItem supports the
> Class property and if the return from that is OlObjectClass.olDocument (41)
> then you know a DocumentItem is being opened.

> >

> http://www.slovaktech.com

> "mightyCoCo" <mightyc...@googlemail.com> wrote in message

> news:802ee580-a7cf-48c1-9b13-24f9b272f4fa@r38g2000yqn.googlegroups.com...
>
> > Hi,

>
> > I'm using the ItemEvents_10_OpenEventHandler to catch a open (double-
> > click) event on a Outlook item.
> > This works great on MailItem or PostItem types. However, Outlook
> > objects of the type DocumentItem dosen't seem to fire this event.
> > Instead I'm directly presented wih the document in it's native
> > application.

>
> > Is this a known restriction?
> > (Outlook 2007, VS2005)

>
> > thanks in advance,
> > -coco


Hi Ken,

I tried using the NewInspector event handler. It's not fired either,

as Outlook doesn't seem to open an Insspector at all for a

DocumentItem.

Let's say the DocumentItem object in my Inbox is a .html object. If i

select it, in the preview pane the html file is rendered. If i double

click the object, Internet Explorer opens. The double click doesn't

open a new Inspector or triggers the Open event. It seems that Outlook

is directly running the process which is assigned to the object class

(Word for .doc, IE for .html, Notepad for .txt, etc...)

I wonder if I need to set the MessageClass of the object to something

else than IPM.Document, to trigger the event... But i guess, I'd loose

the document-specific icon in the Outlook list view then...

thanks,

-coco
 
Status
Not open for further replies.
Similar threads
Thread starter Title Forum Replies Date
D Send on behalf of does not store the base mailbox Using Outlook 0
e_a_g_l_e_p_i Why does MS do these things???? Using Outlook 4
M "Attachment Detacher for Outlook" add in, does it update the server copy of the email? Using Outlook 1
Witzker Outlook 2019 Edit contact from email does not open the user defined contactform Using Outlook 3
J Event/Meeting in Outlook Does Not Align with SharePoint Calendar Using Outlook 5
C Code to move mail with certain attachment name? Does Not work Outlook VBA and Custom Forms 3
J Does the .fdm contain my custom form? How to make ol use it? - ol2007 Outlook VBA and Custom Forms 4
C Why does Outlook (desktop) 365 for Windows keep making me input my passwords? Using Outlook 12
G Script does not exist Outlook VBA and Custom Forms 0
J WshShell.Popup does't timeout Outlook VBA and Custom Forms 3
N Save selected messages VBA does not save replies and/or messages that contain : in subject Outlook VBA and Custom Forms 1
T Junk Email does not get added to the Blocked Sender List Using Outlook 0
L Does this really work and get thru virus and malware blocks? Using Outlook 3
V Outlook 2016 Does Outlook-2016 (64 bit) work with iCloud for Windows ? Using Outlook 5
F Junk Email does not get added to the Blocked Sender List Using Outlook 4
N Free/busy publish at http location does not work Using Outlook 1
T Why does outlook 2010 convert only some forum notifications to plain text? Using Outlook 0
R Auto display of new email does not work on non-default account Outlook VBA and Custom Forms 0
M Deleting attachments does not reduce file size Using Outlook 0
M vCard does not have user-defined fields from my custom contact form (365) Using Outlook 1
M Outlook .com group does not show up in Outlook for office 365 home Using Outlook 3
W Outlook Calendar does not save view any longer! Using Outlook 3
B Outlook 2016 Does not Shutdown Correctly Using Outlook 3
P Desktop doesn't index Outlook IMAP files, laptop Outlook does index those same IMAP files Using Outlook 2
G Entered data in custom field goes in card and does not stay in list view Outlook VBA and Custom Forms 1
Witzker social connector 2010 does not show all emails to or from contact Using Outlook 3
Witzker social connector 2010 does not show all emails to or from contact Using Outlook 0
Rupert Dragwater Email flag does not show up in Outlook2013 Using Outlook 13
J Outlook 2016 message content does not display - outlook.com; exchange Using Outlook.com accounts in Outlook 9
D Outlook 2016 IMAP Connection Returns All Email but outlook.com does NOT Using Outlook.com accounts in Outlook 2
A BCM does not work anymore! BCM (Business Contact Manager) 1
D Outlook 2016: /altvba startup switch does not work Using Outlook 2
A BCM does not work with Windows 10 1703 any more BCM (Business Contact Manager) 3
S Outlook does not open the .pst file created by the Outlook Using Outlook 5
Q Undisclosed recipients does not include sender Using Outlook 1
N Does a Shared Folder Policy override a Digital Signature Setting for macros? Outlook VBA and Custom Forms 6
E What does mean this icon at the picture attached? Using Outlook 2
O Windows 10 x64 Outlook 2013 - URL does not open (anymore) Using Outlook 3
M How does Outlook determine item numbers in a folder? Outlook VBA and Custom Forms 3
LarryS change day template as cpao does not see .catx files Outlook VBA and Custom Forms 4
C Discovery search does not show autoforwarded messages Exchange Server Administration 1
C Unchecking "Send immediately when connected" does not work on apps that call Outlook Using Outlook 1
J Outlook 2010 VBScript editor does not run code at all Outlook VBA and Custom Forms 0
Mark Foley Time span on WebDAV published Calendars does not appear to be working Using Outlook 7
snhnic Macro that does not overwrite but add a number Outlook VBA and Custom Forms 1
Rupert Dragwater Deleting email from Deleted Items does not work Using Outlook 0
G Outlook does not show new appointments in To-Do-Bar Using Outlook 0
G Calendar does not point to deafult data file Using Outlook 0
Diane Poremsky What does the "J" mean? Using Outlook 0
Christiaan Could not complete operation because the service provider does not support it Using Outlook 2

Similar threads

Back
Top