00shoe
Member
- Joined
- Oct 12, 2006
- Messages
- 20
- Programming Experience
- 3-5
Hey,
I searched this forum and could not find any post/s similar to my problem.
I have an application runinng in a remote desktop session, and it produces the following error:
Problem in StaffOff(): System.Runtime.InteropServices.COMException (0x80010108): The object invoked has disconnected from its clients. at ....
Do any one know what this means?
This error occurs in this block of code (please note that I used an Interop.Outlook Object Library) :
Private Sub sendEmail(ByVal body As String, ByVal subject As String)
Finally what is weird, is that since this program is triggered by a timer; it runs an hour later, and it will work fine (i.e. redo the program functionality and sends and email) the second time through.
Any help would be appreciated.
Thanks.
I searched this forum and could not find any post/s similar to my problem.
I have an application runinng in a remote desktop session, and it produces the following error:
Problem in StaffOff(): System.Runtime.InteropServices.COMException (0x80010108): The object invoked has disconnected from its clients. at ....
Do any one know what this means?
This error occurs in this block of code (please note that I used an Interop.Outlook Object Library) :
Private Sub sendEmail(ByVal body As String, ByVal subject As String)
' Create an Outlook application.
Dim oApp As Outlook._Application
--Error Occurs Here
oApp = New Outlook.Application
' Create a new MailItem.
Dim oMsg As Outlook._MailItem
oMsg = oApp.CreateItem(Outlook.OlItemType.olMailItem)
oMsg.Subject = subject
oMsg.Body = body & vbCrLf
oMsg.To = "emailAddress"
' Send
oMsg.Send()
' Clean up
oApp = Nothing
oMsg = Nothing
End SubFinally what is weird, is that since this program is triggered by a timer; it runs an hour later, and it will work fine (i.e. redo the program functionality and sends and email) the second time through.
Any help would be appreciated.
Thanks.
Last edited: