Article ID: 201051
Article Last Modified on 11/23/2006
Function Item_CustomAction(ByVal Action, ByVal NewItem) Item.Close 1 'olDiscard End Function
Sub CommandButton1_Click()
' Create a reference to the Inbox
Set MyInbox = Application.GetNamespace("MAPI").GetDefaultFolder(6)
' Create a new instance of Form2
Set NewItem = MyInbox.Items.Add("IPM.Note.Form2")
' Address the form and populate its fields
NewItem.To = "emailname"
NewItem.Subject = "This is form2"
' Send the second form
NewItem.Send
' Close the current (first) form
Item.Close 1
End Sub
146636 OL2000: Questions About Custom Forms and Outlook Solutions
Additional query words: OutSol OutSol2000 OL2K
Keywords: kbhowto kbprogramming KB201051