M
Mat Farabee
I'm saving an Outlook message in .msg format using the Redemption library
(SafeMailItem.SaveAs). The message appears to be saved successfully, but I
get the error
"Unable to read the item" when I try to open it. This problem does *not*
occur when I run the application on my own PC (Win 2000 Professional); it
only occurs when the application is run on the servers (two servers tested,
both Win 2000 Server). The save filenames are "00000001.msg",
"00000002.msg", etc. Code is listed below.
Has anyone encountered this problem before?
- Mat Farabee
Sub SaveMessage(objMessage As MAPI.Message, strSaveAs As String)
' Declarations
Dim objRedMessage As Object
Dim FSO As New Scripting.FileSystemObject
' Save file if it doesn't already exist
If Not FSO.FileExists(strSaveAs) Then
' Create new Redemption SafeMailItem object
Set objRedMessage = New Redemption.SafeMailItem
objRedMessage.Item = objMessage
' Save message
objRedMessage.SaveAs strSaveAs, 3 ' .msg format
End if
' Clean up
Set objRedMessage = Nothing
Set FSO = Nothing
End Sub
(SafeMailItem.SaveAs). The message appears to be saved successfully, but I
get the error
"Unable to read the item" when I try to open it. This problem does *not*
occur when I run the application on my own PC (Win 2000 Professional); it
only occurs when the application is run on the servers (two servers tested,
both Win 2000 Server). The save filenames are "00000001.msg",
"00000002.msg", etc. Code is listed below.
Has anyone encountered this problem before?
- Mat Farabee
Sub SaveMessage(objMessage As MAPI.Message, strSaveAs As String)
' Declarations
Dim objRedMessage As Object
Dim FSO As New Scripting.FileSystemObject
' Save file if it doesn't already exist
If Not FSO.FileExists(strSaveAs) Then
' Create new Redemption SafeMailItem object
Set objRedMessage = New Redemption.SafeMailItem
objRedMessage.Item = objMessage
' Save message
objRedMessage.SaveAs strSaveAs, 3 ' .msg format
End if
' Clean up
Set objRedMessage = Nothing
Set FSO = Nothing
End Sub