Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Web CMS (TeamSite)
Cannot open Outlook Emails via SDK
Rooose
Hi there,
I'm having a problem with opening Outlook 2003 e-mails through the SDK. However if i close Outlook down and try to open an e-mail it opens it ok!? This seems to have come to my attention since upgrading to Worksite 8.2
Heres my VB:
Public Function openDocument(ByVal lHwnd As Long, _
ByVal sMoniker As String) As String
' Open a document for editing
Dim oOpen As Imanextlib.OpenCmd
Dim oDocument(0) As IManage.NRTDocument
On Error GoTo errBlock
Set oDocument(0) = oWorksiteDMS.GetObjectBySID(sMoniker)
Set oWrkContextItems = New Imanextlib.ContextItems
With oWrkContextItems
.Add "ParentWindow", lHwnd
.Add "iManExt.OpenCmd.NoCmdUI", True
.Add "SelectedNRTDocuments", oDocument
End With
Set oOpen = New Imanextlib.OpenCmd
With oOpen
.Initialize oWrkContextItems
.Update
If .Status = _
(.Status And nrActiveCommand) Then _
.Execute
End With
Err.Clear
errBlock:
If Err.Number <> 0 Then openDocument = "ERROR: Cannot open document" & vbCr & Err.Description
Set oDocument(0) = Nothing
Set oWrkContextItems = Nothing
Set oOpen = Nothing
End Function
Many thanks in advance.
RW
Find more posts tagged with
Comments
jny
This is a bug. As a workaround, call GetCopy to download the e-mail file locally to open it using Windows or Outlook Object Model APIs.