Article ID: 178343
Article Last Modified on 2/12/2007
Sub CommandButton1_Click()
' Set the NameSpace object.
Set olns = Item.Application.GetNameSpace("MAPI")
' MyFolder is a variant variable whose subtype is "object" since
' a Set statement is used.
Set MyMailbox = olns.Folders("Mailbox - John Smith")
Set Myfolder = MyMailbox.Folders("FolderName")
' Correctly sets the folder where the "sent item" will be stored.
Set Item.SaveSentMessageFolder = MyFolder
' Sends the current mail item.
Item.Send
End Sub
166368 OL97: How to Get Help Programming with Outlook
170783 OL97: Q&A: Questions about Customizing or Programming Outlook
Additional query words: OutSol OutSol97
Keywords: kbcode kbprb kbprogramming KB178343