Re: Sending saved emails .net
You would have to send the SOAP trace of the send.
>>> On Wednesday, September 02, 2009 at 10:05 AM, Brian
W<nospam@nospam.org>
wrote:
> The items aren't ever sent though, or is deleting the draft part of the
> send. I send the items and they never are delivered to recipients, and do
> not show in the sent items folder.
>
>
> "Preston Stephenson" <PStephenson@gw.novell.com> wrote in message
> news:4A9E1161.07F1.0037.1@gw.novell.com...
>> The code doesn't work like the Object API.
>> You are sending a copy of the data. After
>> you send the item, you will have to explicitly
>> delete the draft item.
>>
>>>>> On Tuesday, September 01, 2009 at 5:24 PM, Brian W<nospam@nospam.org>
>> wrote:
>>> I've successfully pulled a listing of all the saved emails in the 'Work
>>> in
>>
>>> Progress' folder, now I'd like to know how to send them. I'm doing it
in
>>> vb.net, but any .net code would be helpful, I'm using the code below. I
>> get
>>> response codes from the sendItemRequest of 0 which I believe is
success,
>> and
>>>
>>> the program is successfully finding the emails I want to send, but the
>> items
>>>
>>> still remain in the work in progress folder and are never actually
sent.
>> Am
>>> I missing something? If so what?
>>>
>>> Thanks in advance.
>>> Brian W.
>>>
>>> Public Sub SendDraftMessages()
>>> Dim mlReq As New GWWS.getItemsRequest()
>>> Dim mlResp As GWWS.getItemsResponse
>>>
>>> mlReq.container = cmboFolders.SelectedValue 'SelectedValue is
>> 'Work
>>> in Progress folder's ID.
>>> mlResp = wsGWBinding.getItemsRequest(mlReq)
>>> If IsNothing(mlResp.items) = False Then
>>> For Each theItem As GWWS.Mail In mlResp.items
>>> Dim gwSendReq As New GWWS.sendItemRequest
>>> Dim gwSendResp As New GWWS.sendItemResponse
>>>
>>> gwSendReq.item = theItem
>>> gwSendResp = wsGWBinding.sendItemRequest(gwSendReq)
>>> If gwSendResp.status.code = 0 Then
>>> ReportStuff("Successfully sent mail item: " &
>>> theItem.distribution.to)
>>> Else
>>> ReportStuff("Failed to send mail item, code: " &
>>> gwSendResp.status.code)
>>> End If
>>> Next
>>> End If
>>> End Sub
|