A
a6avant
Hello,
I've created a custom form based on a message which allows to enter
data for a hardware purchase and a button to "Send to manager". The
user can fill this in and choose someone from the GAL to send the form
to.
The recipient receives this form (as a "note" icon in his inbox ?) and
when opening it he can approve the purchase and click on the approve
button or he can reject the purchase with a reject button. The form
thus has a different "read" and "compose page".
The problem is that whenever the user clicks approve the mail is
"forwarded" with a few lines of code to an external smtp-adres so the
form leaves the Exchange org. The recipient is also on Exchange, has a
copy of the form published in his Personal Forms Library and has the
flag "use MAPI Rich Text" in his Exchange properties in AD (on the
sending Exchange server).
However the recipient is receiving empty mails.
I had to go for forward because the approving manager upon opening the
mail the mail is "read" and cannot be resend from code without
forwarding it (I guess).
The code used behind the button is :
Sub CommandButton2_Click()
Set objNewItem = Item.Forward 'This is the line that causes the
error!
objNewItem.To = "(e-mail address removed)"
objNewItem.Recipients.ResolveAll
objNewItem.Send
End Sub
I really would appreciate some help on this.
I've created a custom form based on a message which allows to enter
data for a hardware purchase and a button to "Send to manager". The
user can fill this in and choose someone from the GAL to send the form
to.
The recipient receives this form (as a "note" icon in his inbox ?) and
when opening it he can approve the purchase and click on the approve
button or he can reject the purchase with a reject button. The form
thus has a different "read" and "compose page".
The problem is that whenever the user clicks approve the mail is
"forwarded" with a few lines of code to an external smtp-adres so the
form leaves the Exchange org. The recipient is also on Exchange, has a
copy of the form published in his Personal Forms Library and has the
flag "use MAPI Rich Text" in his Exchange properties in AD (on the
sending Exchange server).
However the recipient is receiving empty mails.
I had to go for forward because the approving manager upon opening the
mail the mail is "read" and cannot be resend from code without
forwarding it (I guess).
The code used behind the button is :
Sub CommandButton2_Click()
Set objNewItem = Item.Forward 'This is the line that causes the
error!
objNewItem.To = "(e-mail address removed)"
objNewItem.Recipients.ResolveAll
objNewItem.Send
End Sub
I really would appreciate some help on this.