Can't find the information you are looking for here? Then leave a message over on our WinBatch Tech Support Forum.
I can log into the server. Massage the information, but do not see documentation on how to delete the message. I tried using postie, but it is not available as we do not allow pop/imap checking on the exchange server.
; I assume you want to delete mail in the INBOX... ; try putting three emails into the INBOX and deleting them all. objOutlook = ObjectOpen("Outlook.Application") oln = objOutlook.GetNameSpace("MAPI") oln.logon("", "", 0, 1) ;userid/password combo...try it blank ; ; Find the Mailbox Folder... For x = 1 To oln.Folders.count ;loop once for each folder If StrIndexNC(oln.Folders.item(x).name, "Mailbox -", 1, @FWDSCAN);< find user Mail Box Message("Debug", oln.Folders.item(x).name) MainFolder = oln.Folders.item(x).folders Inbox = MainFolder.item("Inbox") ;<-- Inbox break endif Next ; for x = 1 to Inbox.items.count ;<-- loop thru the inbox's items... ThisMsg = Inbox.items(x) DaSubject = ThisMsg.subject DaBody = ThisMsg.body DaTo = ThisMsg.To DaSentBy = ThisMsg.SenderName DaReceived= ThisMsg.ReceivedTime FileName = strcat("c:\Email Message ", x, ".txt") ;<-- you'll have to come up with something more elaborate... Filebody = strcat("Sent By: ", DaSentBy, @crlf, "Received at: ", DaReceived, @crlf, "Sent To: ", DaTo, @crlf) Filebody = strcat(Filebody, "Subject: ", DaSubject, @crlf, @crlf, DaBody) message("Item #%x%", Filebody) if askyesno("Outlook", "Delete this email?") ThisMsg.delete x = x - 1 ;must decrement loop because inbox count auto decrements... ; fileput(FileName, Filebody) ;<-- UNCOMMENT -- this may over write existing files... endif next ; message("Debug", "All Done") ; MainFolder = 0 Inbox = 0 objOutlook = 0 oln = 0 ; Exit
Article ID: W17193
File Created: 2007:07:03:14:28:40
Last Updated: 2007:07:03:14:28:40