Question
Outlook Retrieve Mail Exception - Outlook Connector Issue
Hi Team,
We are getting below exception while running the Outook connector - Retrieve Email Method. Solution is working fine for 10 to 15 minutes, after few minutes - randomaly getting exception and Pega runtime is not responding.
Exception Information ********************************************* Exception Type: System.ComponentModel.Win32Exception NativeErrorCode: 1158 ErrorCode: -2147467259 Message: "Error creating window handle." Data: IDictionary (System.Collections.ListDictionaryInternal) with 0 items TargetSite: Void CreateHandle(System.Windows.Forms.CreateParams) HelpLink: NULL Source: "System.Windows.Forms" HResult: -2147467259
StackTrace Information ********************************************* at System.Windows.Forms.NativeWindow.CreateHandle(CreateParams cp) at System.Windows.Forms.Control.CreateHandle() at System.Windows.Forms.Control.get_Handle() at OpenSpan.Office.MicrosoftOfficeBase..ctor() at OpenSpan.Office.MicrosoftOutlookMail..ctor(MailItem mailItem, Boolean hookEvents) at OpenSpan.Office.MicrosoftOutlook.HookMailItemEvents(MailItem item) at OpenSpan.Office.MicrosoftOutlook.InternalRetrieveEmail(String folder, ReadType readType, MAPIFolder& retrieveFolder) at OpenSpan.Office.MicrosoftOutlook.RetrieveEmail(String folder, ReadType readType)
That stack trace seems to indicate the error is with Outlook. Perhaps there is something wrong with the installation. It looks like that error can be caused by a memory leak, so perhaps you have an older version of Outlook that errors after N emails are opened.
If Pega Robotics is responsible though, I would suggest that you open an SR and record the SR number on this post in case any resolution is found.