Kbase P147155: Error 12869 when using Microsoft Outlook Interop controls in OpenEdge 10.2A
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  1/7/2010 |
|
Status: Verified
SYMPTOM(s):
Error 12869 when using Microsoft Outlook Interop controls in OpenEdge 10.2A
Attempting to CAST what should be an Outlook.Items collection to interface Microsoft.Office.Interop.Outlook.Items fails with error 12869
Attempting to CAST what should be a ContactItem to interface Microsoft.Office.Interop.Outlook.ContactItem fails with error 12869
Attempting to CAST what should be a AppointmentItem to interface Microsoft.Office.Interop.Outlook._AppointmentItem fails with error 12869
Invalid cast from <name> to <name>. (12869)
Invalid cast from System.__ComObject to Microsoft.Office.Interop.Outlook.Items, Microsoft.Office.Interop.Outlook, Version 11.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c. (12869)
FACT(s) (Environment):
Using Microsoft.Office.Interop.Outlook in an attempt to display Outlook Contacts
Equivalent code written in Visual Basic .NET works as expected
The following results are returned when displaying object Types in Visual Basic .NET
outLookApp = Microsoft.Office.Interop.Outlook.ApplicationClass
folderContacts = System.__ComObject
folderContacts.Items = Microsoft.Office.Interop.Outlook.ItemsClass
myItems = Microsoft.Office.Interop.Outlook.ItemsClass
The following results are returned when displaying object Types in OpenEdge 10.2A01:
outLookApp = Microsoft.Office.Interop.Outlook.ApplicationClass
folderContacts = System.__ComObject
folderContacts.Items = System.__ComObject
myItems = System.__ComObject
OpenEdge 10.2A
Windows
CAUSE:
Bug# OE00185269
CAUSE:
The code in the .NET bridge that handles CAST and TYPE-OF functionality for a .NET object did not take into account the fact that some COM interfaces are supported in the standard Object-Orientated manner, whilst others are supported in the standard COM way, via QueryInterface
FIX:
Upgrade to OpenEdge 10.2B or later