C
cj
My application, brx729, creates a new MAPI email message and leaves it
on the screen for the user to send. On one pc when it creates the email
if you cancel the message my program throws the error
System.Runtime.InteropServices.COMException (0x800A7D01): User cancelled
process
at MSMAPI.MAPIMessagesClass.Send(Object vDialog)
at brx729.Form1.SndMAPIMail(String subj, String msg)
at brx729.Form1.MailMenuItem_Click(Object sender, EventArgs e)
at System.Windows.Forms.MenuItem.OnClick(EventArgs e)
at System.Windows.Forms.MenuItemData.Execute()
at System.Windows.Forms.Command.Invoke()
at System.Windows.Forms.Control.WmCommand(Message& m)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
at System.Windows.Forms.ContainerControl.WndProc(Message& m)
at System.Windows.Forms.Form.WndProc(Message& m)
at System.Windows.Forms.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32
msg, IntPtr wparam, IntPtr lparam)
On my pc it doesn't show any error. I have installed the program on the
network so we're using the same exe.
Here's my sub that creates the email.
Private Sub SndMAPIMail(ByVal subj As String, ByVal msg As String)
Dim myMAPISession As New MSMAPI.MAPISession
Dim myMAPIMessage As New MSMAPI.MAPIMessages
myMAPISession.DownLoadMail = False
myMAPISession.SignOn()
myMAPISession.NewSession = True
myMAPIMessage.SessionID = myMAPISession.SessionID
myMAPIMessage.Compose()
myMAPIMessage.MsgSubject = subj
myMAPIMessage.MsgNoteText = msg
myMAPIMessage.Send(True)
myMAPISession.SignOff()
myMAPISession.NewSession = False
End Sub
Any idea what is going on?
on the screen for the user to send. On one pc when it creates the email
if you cancel the message my program throws the error
System.Runtime.InteropServices.COMException (0x800A7D01): User cancelled
process
at MSMAPI.MAPIMessagesClass.Send(Object vDialog)
at brx729.Form1.SndMAPIMail(String subj, String msg)
at brx729.Form1.MailMenuItem_Click(Object sender, EventArgs e)
at System.Windows.Forms.MenuItem.OnClick(EventArgs e)
at System.Windows.Forms.MenuItemData.Execute()
at System.Windows.Forms.Command.Invoke()
at System.Windows.Forms.Control.WmCommand(Message& m)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
at System.Windows.Forms.ContainerControl.WndProc(Message& m)
at System.Windows.Forms.Form.WndProc(Message& m)
at System.Windows.Forms.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32
msg, IntPtr wparam, IntPtr lparam)
On my pc it doesn't show any error. I have installed the program on the
network so we're using the same exe.
Here's my sub that creates the email.
Private Sub SndMAPIMail(ByVal subj As String, ByVal msg As String)
Dim myMAPISession As New MSMAPI.MAPISession
Dim myMAPIMessage As New MSMAPI.MAPIMessages
myMAPISession.DownLoadMail = False
myMAPISession.SignOn()
myMAPISession.NewSession = True
myMAPIMessage.SessionID = myMAPISession.SessionID
myMAPIMessage.Compose()
myMAPIMessage.MsgSubject = subj
myMAPIMessage.MsgNoteText = msg
myMAPIMessage.Send(True)
myMAPISession.SignOff()
myMAPISession.NewSession = False
End Sub
Any idea what is going on?