/ Forums / Advansys Formativ / Creating Solutions with Formativ / Creating Email in Proxy Account without UI / Reply To: Creating Email in Proxy Account without UI
March 16, 2004 at 6:22 pm
#6933
Thank you for your query.
The technique required to create email in a proxy account is similar to that from your previous post on EmailAddress from ProxyAccount.
Here is an example:
' This example assumes the GroupWise client has been proxied to another account.
Sub Main(Client, GWEvent)
dim oAccount
dim oDraft
dim oSent
set oAccount = Client.ClientState.CurrentAccount
set oDraft = oAccount.WorkFolder.Messages.Add("GW.MESSAGE.MAIL", fgwDraft)
call oDraft.Recipients.Add(oAccount.Owner.EmailAddress, "NGW", fgwTo)
oDraft.Subject.PlainText = "This was created using Formativ"
oDraft.BodyText.PlainText = "This is the body text of the email message"
set oSent = oDraft.send
set oSent = nothing
set oDraft = nothing
set oAccount = nothing
End Sub
I hope this helps.
Advansys Support